@ui5/cli 2.14.10 → 2.14.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -2
- package/bin/ui5.js +20 -8
- package/lib/cli/update-notifier.js +12 -0
- package/npm-shrinkwrap.json +438 -369
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -2,10 +2,22 @@
|
|
|
2
2
|
All notable changes to this project will be documented in this file.
|
|
3
3
|
This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
4
4
|
|
|
5
|
-
A list of unreleased changes can be found [here](https://github.com/SAP/ui5-cli/compare/v2.14.
|
|
5
|
+
A list of unreleased changes can be found [here](https://github.com/SAP/ui5-cli/compare/v2.14.12...HEAD).
|
|
6
|
+
|
|
7
|
+
<a name="v2.14.12"></a>
|
|
8
|
+
## [v2.14.12] - 2022-10-12
|
|
9
|
+
### Dependency Updates
|
|
10
|
+
- Bump [@ui5](https://github.com/ui5)/builder from 2.11.5 to 2.11.6 [`f695e27`](https://github.com/SAP/ui5-cli/commit/f695e2733395599271b1a1059860c519851c7fe7)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
<a name="v2.14.11"></a>
|
|
14
|
+
## [v2.14.11] - 2022-09-05
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
- Upgrade update-notifier to solve security vulnerabilities ([#533](https://github.com/SAP/ui5-cli/issues/533)) [`5b7cfcf`](https://github.com/SAP/ui5-cli/commit/5b7cfcf62c37492c4072c69f400512ef59aab502)
|
|
17
|
+
|
|
6
18
|
|
|
7
19
|
<a name="v2.14.10"></a>
|
|
8
|
-
## [v2.14.10] - 2022-07-
|
|
20
|
+
## [v2.14.10] - 2022-07-25
|
|
9
21
|
|
|
10
22
|
<a name="v2.14.9"></a>
|
|
11
23
|
## [v2.14.9] - 2022-05-04
|
|
@@ -738,6 +750,8 @@ Only Node.js v10 or higher is supported.
|
|
|
738
750
|
<a name="v0.0.1"></a>
|
|
739
751
|
## v0.0.1 - 2018-06-06
|
|
740
752
|
|
|
753
|
+
[v2.14.12]: https://github.com/SAP/ui5-cli/compare/v2.14.11...v2.14.12
|
|
754
|
+
[v2.14.11]: https://github.com/SAP/ui5-cli/compare/v2.14.10...v2.14.11
|
|
741
755
|
[v2.14.10]: https://github.com/SAP/ui5-cli/compare/v2.14.9...v2.14.10
|
|
742
756
|
[v2.14.9]: https://github.com/SAP/ui5-cli/compare/v2.14.8...v2.14.9
|
|
743
757
|
[v2.14.8]: https://github.com/SAP/ui5-cli/compare/v2.14.7...v2.14.8
|
package/bin/ui5.js
CHANGED
|
@@ -38,7 +38,7 @@ if (
|
|
|
38
38
|
console.log("=====================================================================");
|
|
39
39
|
}
|
|
40
40
|
// Timeout is required to log info when importing from local installation
|
|
41
|
-
setTimeout(() => {
|
|
41
|
+
setTimeout(async () => {
|
|
42
42
|
if (!process.env.UI5_CLI_NO_LOCAL) {
|
|
43
43
|
const importLocal = require("import-local");
|
|
44
44
|
// Prefer a local installation of @ui5/cli.
|
|
@@ -57,14 +57,26 @@ if (
|
|
|
57
57
|
}
|
|
58
58
|
}
|
|
59
59
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
updateCheckInterval: 1000 * 60 * 60 * 24, // 1 day
|
|
64
|
-
shouldNotifyInNpmScript: true
|
|
65
|
-
}).notify();
|
|
66
|
-
// Remove --no-update-notifier from argv as it's not known to yargs, but we still want to support using it
|
|
60
|
+
// Only import update-notifier when it's not disabled
|
|
61
|
+
// See https://github.com/yeoman/update-notifier/blob/3046d0f61a57f8270291b6ab271f8a12df8421a6/update-notifier.js#L57-L60
|
|
62
|
+
// The "is-ci" check is not executed, but will be checked by update-notifier itself then
|
|
67
63
|
const NO_UPDATE_NOTIFIER = "--no-update-notifier";
|
|
64
|
+
const disableUpdateNotifier =
|
|
65
|
+
"NO_UPDATE_NOTIFIER" in process.env ||
|
|
66
|
+
process.env.NODE_ENV === "test" ||
|
|
67
|
+
process.argv.includes(NO_UPDATE_NOTIFIER);
|
|
68
|
+
|
|
69
|
+
// Update notifier requires dynamic imports (ES Module) and therefore is loaded via a separate file
|
|
70
|
+
if (
|
|
71
|
+
!disableUpdateNotifier &&
|
|
72
|
+
|
|
73
|
+
// Node.js versions supporting ES modules
|
|
74
|
+
semver.satisfies(nodeVersion, "^12.20 || ^14.14 || >= 16.0", {includePrerelease: true})
|
|
75
|
+
) {
|
|
76
|
+
const updateNotifier = require("../lib/cli/update-notifier");
|
|
77
|
+
await updateNotifier({pkg});
|
|
78
|
+
}
|
|
79
|
+
// Remove --no-update-notifier from argv as it's not known to yargs, but we still want to support using it
|
|
68
80
|
if (process.argv.includes(NO_UPDATE_NOTIFIER)) {
|
|
69
81
|
process.argv = process.argv.filter((v) => v !== NO_UPDATE_NOTIFIER);
|
|
70
82
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// update-notifier is an ES module and therefore needs to be loaded via "import".
|
|
2
|
+
// It is important to have this code in a separate file as this module also
|
|
3
|
+
// supports Node.js versions without dynamic import support (e.g. v10).
|
|
4
|
+
// Otherwise it will lead to syntax errors.
|
|
5
|
+
module.exports = async function({pkg}) {
|
|
6
|
+
const updateNotifier = (await import("update-notifier")).default;
|
|
7
|
+
updateNotifier({
|
|
8
|
+
pkg,
|
|
9
|
+
updateCheckInterval: 1000 * 60 * 60 * 24, // 1 day
|
|
10
|
+
shouldNotifyInNpmScript: true
|
|
11
|
+
}).notify();
|
|
12
|
+
};
|