@angular/cli 12.2.2 → 12.2.6

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.
@@ -1,5 +1,5 @@
1
1
  The command takes an optional project name, as specified in the `projects` section of the `angular.json` workspace configuration file.
2
- When a project name is not supplied, executes the `lint` builder for the default project.
2
+ When a project name is not supplied, executes the `lint` builder for all projects.
3
3
 
4
4
  To use the `ng lint` command, use `ng add` to add a package that implements linting capabilities. Adding the package automatically updates your workspace configuration, adding a lint [CLI builder](guide/cli-builder).
5
5
  For example:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/cli",
3
- "version": "12.2.2",
3
+ "version": "12.2.6",
4
4
  "description": "CLI tool for Angular",
5
5
  "main": "lib/cli/index.js",
6
6
  "bin": {
@@ -28,10 +28,10 @@
28
28
  },
29
29
  "homepage": "https://github.com/angular/angular-cli",
30
30
  "dependencies": {
31
- "@angular-devkit/architect": "0.1202.2",
32
- "@angular-devkit/core": "12.2.2",
33
- "@angular-devkit/schematics": "12.2.2",
34
- "@schematics/angular": "12.2.2",
31
+ "@angular-devkit/architect": "0.1202.6",
32
+ "@angular-devkit/core": "12.2.6",
33
+ "@angular-devkit/schematics": "12.2.6",
34
+ "@schematics/angular": "12.2.6",
35
35
  "@yarnpkg/lockfile": "1.1.0",
36
36
  "ansi-colors": "4.1.1",
37
37
  "debug": "4.3.2",
@@ -51,12 +51,12 @@
51
51
  "ng-update": {
52
52
  "migrations": "@schematics/angular/migrations/migration-collection.json",
53
53
  "packageGroup": {
54
- "@angular/cli": "12.2.2",
55
- "@angular-devkit/architect": "0.1202.2",
56
- "@angular-devkit/build-angular": "12.2.2",
57
- "@angular-devkit/build-webpack": "0.1202.2",
58
- "@angular-devkit/core": "12.2.2",
59
- "@angular-devkit/schematics": "12.2.2"
54
+ "@angular/cli": "12.2.6",
55
+ "@angular-devkit/architect": "0.1202.6",
56
+ "@angular-devkit/build-angular": "12.2.6",
57
+ "@angular-devkit/build-webpack": "0.1202.6",
58
+ "@angular-devkit/core": "12.2.6",
59
+ "@angular-devkit/schematics": "12.2.6"
60
60
  }
61
61
  },
62
62
  "engines": {
@@ -29,7 +29,30 @@ Object.defineProperty(exports, "__esModule", { value: true });
29
29
  exports.colors = exports.removeColor = void 0;
30
30
  const ansiColors = __importStar(require("ansi-colors"));
31
31
  const tty_1 = require("tty");
32
- const supportsColor = process.stdout instanceof tty_1.WriteStream && process.stdout.getColorDepth() > 1;
32
+ function supportColor() {
33
+ if (process.env.FORCE_COLOR !== undefined) {
34
+ // 2 colors: FORCE_COLOR = 0 (Disables colors), depth 1
35
+ // 16 colors: FORCE_COLOR = 1, depth 4
36
+ // 256 colors: FORCE_COLOR = 2, depth 8
37
+ // 16,777,216 colors: FORCE_COLOR = 3, depth 16
38
+ // See: https://nodejs.org/dist/latest-v12.x/docs/api/tty.html#tty_writestream_getcolordepth_env
39
+ // and https://github.com/nodejs/node/blob/b9f36062d7b5c5039498e98d2f2c180dca2a7065/lib/internal/tty.js#L106;
40
+ switch (process.env.FORCE_COLOR) {
41
+ case '':
42
+ case 'true':
43
+ case '1':
44
+ case '2':
45
+ case '3':
46
+ return true;
47
+ default:
48
+ return false;
49
+ }
50
+ }
51
+ if (process.stdout instanceof tty_1.WriteStream) {
52
+ return process.stdout.getColorDepth() > 1;
53
+ }
54
+ return false;
55
+ }
33
56
  function removeColor(text) {
34
57
  // This has been created because when colors.enabled is false unstyle doesn't work
35
58
  // see: https://github.com/doowb/ansi-colors/blob/a4794363369d7b4d1872d248fc43a12761640d8e/index.js#L38
@@ -40,4 +63,4 @@ exports.removeColor = removeColor;
40
63
  // Create function is not defined in the typings. See: https://github.com/doowb/ansi-colors/pull/44
41
64
  const colors = ansiColors.create();
42
65
  exports.colors = colors;
43
- colors.enabled = supportsColor;
66
+ colors.enabled = supportColor();