@angular/cli 8.3.19 → 8.3.20
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/package.json +10 -10
- package/tasks/install-package.js +23 -10
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@angular/cli",
|
|
3
|
-
"version": "8.3.
|
|
3
|
+
"version": "8.3.20",
|
|
4
4
|
"description": "CLI tool for Angular",
|
|
5
5
|
"main": "lib/cli/index.js",
|
|
6
6
|
"bin": {
|
|
@@ -28,11 +28,11 @@
|
|
|
28
28
|
},
|
|
29
29
|
"homepage": "https://github.com/angular/angular-cli",
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@angular-devkit/architect": "0.803.
|
|
32
|
-
"@angular-devkit/core": "8.3.
|
|
33
|
-
"@angular-devkit/schematics": "8.3.
|
|
34
|
-
"@schematics/angular": "8.3.
|
|
35
|
-
"@schematics/update": "0.803.
|
|
31
|
+
"@angular-devkit/architect": "0.803.20",
|
|
32
|
+
"@angular-devkit/core": "8.3.20",
|
|
33
|
+
"@angular-devkit/schematics": "8.3.20",
|
|
34
|
+
"@schematics/angular": "8.3.20",
|
|
35
|
+
"@schematics/update": "0.803.20",
|
|
36
36
|
"@yarnpkg/lockfile": "1.1.0",
|
|
37
37
|
"ansi-colors": "4.1.1",
|
|
38
38
|
"debug": "^4.1.1",
|
|
@@ -52,10 +52,10 @@
|
|
|
52
52
|
"ng-update": {
|
|
53
53
|
"migrations": "@schematics/angular/migrations/migration-collection.json",
|
|
54
54
|
"packageGroup": {
|
|
55
|
-
"@angular/cli": "8.3.
|
|
56
|
-
"@angular-devkit/build-angular": "0.803.
|
|
57
|
-
"@angular-devkit/build-ng-packagr": "0.803.
|
|
58
|
-
"@angular-devkit/build-webpack": "0.803.
|
|
55
|
+
"@angular/cli": "8.3.20",
|
|
56
|
+
"@angular-devkit/build-angular": "0.803.20",
|
|
57
|
+
"@angular-devkit/build-ng-packagr": "0.803.20",
|
|
58
|
+
"@angular-devkit/build-webpack": "0.803.20"
|
|
59
59
|
}
|
|
60
60
|
},
|
|
61
61
|
"engines": {
|
package/tasks/install-package.js
CHANGED
|
@@ -23,16 +23,18 @@ function installPackage(packageName, logger, packageManager = schema_1.PackageMa
|
|
|
23
23
|
packageManagerArgs.noLockfile,
|
|
24
24
|
];
|
|
25
25
|
logger.info(color_1.colors.green(`Installing packages for tooling via ${packageManager}.`));
|
|
26
|
-
const { status } = child_process_1.spawnSync(packageManager, [
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
], {
|
|
30
|
-
stdio: 'inherit',
|
|
26
|
+
const { status, stderr, stdout, error } = child_process_1.spawnSync(packageManager, [...installArgs, ...extraArgs], {
|
|
27
|
+
stdio: 'pipe',
|
|
28
|
+
encoding: 'utf8',
|
|
31
29
|
shell: true,
|
|
32
30
|
cwd,
|
|
33
31
|
});
|
|
34
32
|
if (status !== 0) {
|
|
35
|
-
|
|
33
|
+
let errorMessage = ((error && error.message) || stderr || stdout || '').trim();
|
|
34
|
+
if (errorMessage) {
|
|
35
|
+
errorMessage += '\n';
|
|
36
|
+
}
|
|
37
|
+
throw new Error(errorMessage + `Package install failed${errorMessage ? ', see above' : ''}.`);
|
|
36
38
|
}
|
|
37
39
|
logger.info(color_1.colors.green(`Installed packages for tooling via ${packageManager}.`));
|
|
38
40
|
}
|
|
@@ -46,6 +48,20 @@ function installTempPackage(packageName, logger, packageManager = schema_1.Packa
|
|
|
46
48
|
}
|
|
47
49
|
catch (_a) { }
|
|
48
50
|
});
|
|
51
|
+
// NPM will warn when a `package.json` is not found in the install directory
|
|
52
|
+
// Example:
|
|
53
|
+
// npm WARN enoent ENOENT: no such file or directory, open '/tmp/.ng-temp-packages-84Qi7y/package.json'
|
|
54
|
+
// npm WARN .ng-temp-packages-84Qi7y No description
|
|
55
|
+
// npm WARN .ng-temp-packages-84Qi7y No repository field.
|
|
56
|
+
// npm WARN .ng-temp-packages-84Qi7y No license field.
|
|
57
|
+
// While we can use `npm init -y` we will end up needing to update the 'package.json' anyways
|
|
58
|
+
// because of missing fields.
|
|
59
|
+
fs_1.writeFileSync(path_1.join(tempPath, 'package.json'), JSON.stringify({
|
|
60
|
+
name: 'temp-cli-install',
|
|
61
|
+
description: 'temp-cli-install',
|
|
62
|
+
repository: 'temp-cli-install',
|
|
63
|
+
license: 'MIT',
|
|
64
|
+
}));
|
|
49
65
|
// setup prefix/global modules path
|
|
50
66
|
const packageManagerArgs = getPackageManagerArguments(packageManager);
|
|
51
67
|
const tempNodeModules = path_1.join(tempPath, 'node_modules');
|
|
@@ -85,10 +101,7 @@ function runTempPackageBin(packageName, logger, packageManager = schema_1.Packag
|
|
|
85
101
|
if (!binPath) {
|
|
86
102
|
throw new Error(`Cannot locate bin for temporary package: ${packageNameNoVersion}.`);
|
|
87
103
|
}
|
|
88
|
-
const argv = [
|
|
89
|
-
binPath,
|
|
90
|
-
...args,
|
|
91
|
-
];
|
|
104
|
+
const argv = [binPath, ...args];
|
|
92
105
|
const { status, error } = child_process_1.spawnSync('node', argv, {
|
|
93
106
|
stdio: 'inherit',
|
|
94
107
|
shell: true,
|