nx 19.6.1 → 19.6.3

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.
Files changed (44) hide show
  1. package/.eslintrc.json +12 -1
  2. package/README.md +1 -1
  3. package/package.json +12 -12
  4. package/src/command-line/add/add.js +1 -5
  5. package/src/command-line/add/command-object.js +1 -5
  6. package/src/command-line/affected/affected.js +0 -3
  7. package/src/command-line/exec/exec.js +0 -3
  8. package/src/command-line/generate/command-object.js +2 -5
  9. package/src/command-line/generate/generate.js +4 -8
  10. package/src/command-line/graph/graph.d.ts +18 -1
  11. package/src/command-line/import/command-object.js +1 -1
  12. package/src/command-line/import/utils/prepare-source-repo.js +2 -2
  13. package/src/command-line/migrate/command-object.js +3 -2
  14. package/src/command-line/migrate/migrate.js +5 -39
  15. package/src/command-line/release/changelog.js +0 -3
  16. package/src/command-line/release/command-object.js +1 -5
  17. package/src/command-line/release/plan-check.js +0 -3
  18. package/src/command-line/release/plan.js +0 -3
  19. package/src/command-line/release/publish.js +0 -6
  20. package/src/command-line/release/release.js +0 -3
  21. package/src/command-line/release/version.js +0 -3
  22. package/src/command-line/repair/command-object.js +2 -4
  23. package/src/command-line/repair/repair.js +2 -6
  24. package/src/command-line/run/run-one.js +0 -3
  25. package/src/command-line/show/command-object.js +2 -2
  26. package/src/command-line/sync/command-object.js +3 -8
  27. package/src/command-line/sync/sync.js +1 -5
  28. package/src/command-line/watch/command-object.js +1 -1
  29. package/src/command-line/watch/watch.js +0 -3
  30. package/src/command-line/yargs-utils/shared-options.d.ts +2 -1
  31. package/src/command-line/yargs-utils/shared-options.js +14 -18
  32. package/src/core/graph/main.js +1 -1
  33. package/src/core/graph/styles.js +1 -1
  34. package/src/daemon/client/client.js +4 -2
  35. package/src/devkit-exports.d.ts +1 -0
  36. package/src/native/assert-supported-platform.js +1 -1
  37. package/src/native/nx.wasm32-wasi.wasm +0 -0
  38. package/src/nx-cloud/utilities/url-shorten.js +1 -1
  39. package/src/plugins/js/package-json/create-package-json.d.ts +1 -0
  40. package/src/plugins/js/package-json/create-package-json.js +1 -1
  41. package/src/plugins/js/project-graph/build-dependencies/target-project-locator.js +11 -6
  42. package/src/tasks-runner/cache.js +1 -1
  43. package/src/utils/git-utils.js +1 -1
  44. package/src/utils/logger.js +1 -1
@@ -1,5 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.defaultYargsParserConfiguration = void 0;
3
4
  exports.withExcludeOption = withExcludeOption;
4
5
  exports.withRunOptions = withRunOptions;
5
6
  exports.withTargetAndConfigurationOption = withTargetAndConfigurationOption;
@@ -12,6 +13,13 @@ exports.withOverrides = withOverrides;
12
13
  exports.withOutputStyleOption = withOutputStyleOption;
13
14
  exports.withRunOneOptions = withRunOneOptions;
14
15
  exports.parseCSV = parseCSV;
16
+ exports.defaultYargsParserConfiguration = {
17
+ 'strip-dashed': true,
18
+ 'unknown-options-as-args': true,
19
+ 'populate--': true,
20
+ 'parse-numbers': false,
21
+ 'parse-positional-numbers': false,
22
+ };
15
23
  function withExcludeOption(yargs) {
16
24
  return yargs.option('exclude', {
17
25
  describe: 'Exclude certain projects from being processed',
@@ -111,9 +119,9 @@ function withVerbose(yargs) {
111
119
  type: 'boolean',
112
120
  })
113
121
  .middleware((args) => {
114
- if (args.verbose) {
115
- process.env.NX_VERBOSE_LOGGING = 'true';
116
- }
122
+ args.verbose ??= process.env.NX_VERBOSE_LOGGING === 'true';
123
+ // If NX_VERBOSE_LOGGING=false and --verbose is passed, we want to set it to true favoring the arg
124
+ process.env.NX_VERBOSE_LOGGING = args.verbose.toString();
117
125
  });
118
126
  }
119
127
  function withBatch(yargs) {
@@ -128,11 +136,7 @@ function withBatch(yargs) {
128
136
  }
129
137
  function withAffectedOptions(yargs) {
130
138
  return withExcludeOption(yargs)
131
- .parserConfiguration({
132
- 'strip-dashed': true,
133
- 'unknown-options-as-args': true,
134
- 'populate--': true,
135
- })
139
+ .parserConfiguration(exports.defaultYargsParserConfiguration)
136
140
  .option('files', {
137
141
  describe: 'Change the way Nx is calculating the affected command by providing directly changed files, list of files delimited by commas or spaces',
138
142
  type: 'string',
@@ -169,11 +173,7 @@ function withAffectedOptions(yargs) {
169
173
  }
170
174
  function withRunManyOptions(yargs) {
171
175
  return withRunOptions(yargs)
172
- .parserConfiguration({
173
- 'strip-dashed': true,
174
- 'unknown-options-as-args': true,
175
- 'populate--': true,
176
- })
176
+ .parserConfiguration(exports.defaultYargsParserConfiguration)
177
177
  .option('projects', {
178
178
  type: 'string',
179
179
  alias: 'p',
@@ -225,11 +225,7 @@ function withOutputStyleOption(yargs, choices = [
225
225
  function withRunOneOptions(yargs) {
226
226
  const executorShouldShowHelp = !(process.argv[2] === 'run' && process.argv[3] === '--help');
227
227
  const res = withRunOptions(withOutputStyleOption(withConfiguration(yargs), allOutputStyles))
228
- .parserConfiguration({
229
- 'strip-dashed': true,
230
- 'unknown-options-as-args': true,
231
- 'populate--': true,
232
- })
228
+ .parserConfiguration(exports.defaultYargsParserConfiguration)
233
229
  .option('project', {
234
230
  describe: 'Target project',
235
231
  type: 'string',