@angular/cli 11.2.1 → 11.2.2

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/bin/ng CHANGED
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/cli",
3
- "version": "11.2.1",
3
+ "version": "11.2.2",
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.1102.1",
32
- "@angular-devkit/core": "11.2.1",
33
- "@angular-devkit/schematics": "11.2.1",
34
- "@schematics/angular": "11.2.1",
35
- "@schematics/update": "0.1102.1",
31
+ "@angular-devkit/architect": "0.1102.2",
32
+ "@angular-devkit/core": "11.2.2",
33
+ "@angular-devkit/schematics": "11.2.2",
34
+ "@schematics/angular": "11.2.2",
35
+ "@schematics/update": "0.1102.2",
36
36
  "@yarnpkg/lockfile": "1.1.0",
37
37
  "ansi-colors": "4.1.1",
38
38
  "debug": "4.3.1",
@@ -54,17 +54,17 @@
54
54
  "ng-update": {
55
55
  "migrations": "@schematics/angular/migrations/migration-collection.json",
56
56
  "packageGroup": {
57
- "@angular/cli": "11.2.1",
58
- "@angular-devkit/architect": "0.1102.1",
59
- "@angular-devkit/build-angular": "0.1102.1",
60
- "@angular-devkit/build-webpack": "0.1102.1",
61
- "@angular-devkit/core": "11.2.1",
62
- "@angular-devkit/schematics": "11.2.1"
57
+ "@angular/cli": "11.2.2",
58
+ "@angular-devkit/architect": "0.1102.2",
59
+ "@angular-devkit/build-angular": "0.1102.2",
60
+ "@angular-devkit/build-webpack": "0.1102.2",
61
+ "@angular-devkit/core": "11.2.2",
62
+ "@angular-devkit/schematics": "11.2.2"
63
63
  }
64
64
  },
65
65
  "engines": {
66
66
  "node": ">= 10.13.0",
67
- "npm": "^6.11.0",
67
+ "npm": "^6.11.0 || ^7.5.6",
68
68
  "yarn": ">= 1.13.0"
69
69
  }
70
70
  }
@@ -3,6 +3,6 @@ export declare function supportsYarn(): boolean;
3
3
  export declare function supportsNpm(): boolean;
4
4
  export declare function getPackageManager(root: string): Promise<PackageManager>;
5
5
  /**
6
- * Checks if the npm version is version 6.x. If not, display a message and exit.
6
+ * Checks if the npm version is a supported 7.x version. If not, display a warning.
7
7
  */
8
8
  export declare function ensureCompatibleNpm(root: string): Promise<void>;
@@ -11,6 +11,7 @@ exports.ensureCompatibleNpm = exports.getPackageManager = exports.supportsNpm =
11
11
  const child_process_1 = require("child_process");
12
12
  const fs_1 = require("fs");
13
13
  const path_1 = require("path");
14
+ const semver_1 = require("semver");
14
15
  const schema_1 = require("../lib/config/schema");
15
16
  const config_1 = require("./config");
16
17
  function supports(name) {
@@ -57,27 +58,25 @@ async function getPackageManager(root) {
57
58
  }
58
59
  exports.getPackageManager = getPackageManager;
59
60
  /**
60
- * Checks if the npm version is version 6.x. If not, display a message and exit.
61
+ * Checks if the npm version is a supported 7.x version. If not, display a warning.
61
62
  */
62
63
  async function ensureCompatibleNpm(root) {
63
- var _a;
64
64
  if ((await getPackageManager(root)) !== schema_1.PackageManager.Npm) {
65
65
  return;
66
66
  }
67
67
  try {
68
- const version = child_process_1.execSync('npm --version', { encoding: 'utf8', stdio: 'pipe' }).trim();
69
- const major = Number((_a = version.match(/^(\d+)\./)) === null || _a === void 0 ? void 0 : _a[1]);
70
- if (major <= 6) {
68
+ const versionText = child_process_1.execSync('npm --version', { encoding: 'utf8', stdio: 'pipe' }).trim();
69
+ const version = semver_1.valid(versionText);
70
+ if (!version) {
71
71
  return;
72
72
  }
73
- // tslint:disable-next-line: no-console
74
- console.error(`npm version ${version} detected. The Angular CLI temporarily requires npm version 6 while upstream issues are addressed.\n\n` +
75
- 'Please install a compatible version to proceed (`npm install --global npm@6`).\n' +
76
- 'For additional information and alternative workarounds, please see ' +
77
- 'https://github.com/angular/angular-cli/issues/19957#issuecomment-775407654');
78
- process.exit(3);
73
+ if (semver_1.satisfies(version, '>=7 <7.5.6')) {
74
+ // tslint:disable-next-line: no-console
75
+ console.warn(`npm version ${version} detected.` +
76
+ ' When using npm 7 with the Angular CLI, npm version 7.5.6 or higher is recommended.');
77
+ }
79
78
  }
80
- catch (_b) {
79
+ catch (_a) {
81
80
  // npm is not installed
82
81
  }
83
82
  }