nx 18.1.0-canary.20240309-235ca8c → 18.1.0-canary.20240313-81df848

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 (82) hide show
  1. package/bin/post-install.js +5 -7
  2. package/package.json +12 -12
  3. package/src/adapter/angular-json.d.ts +1 -2
  4. package/src/adapter/angular-json.js +0 -1
  5. package/src/adapter/ngcli-adapter.js +3 -3
  6. package/src/command-line/generate/generator-utils.js +2 -2
  7. package/src/command-line/run/executor-utils.js +2 -2
  8. package/src/config/schema-utils.js +2 -2
  9. package/src/core/graph/3rdpartylicenses.txt +51 -0
  10. package/src/core/graph/main.js +1 -1
  11. package/src/core/graph/polyfills.js +1 -1
  12. package/src/core/graph/runtime.js +1 -1
  13. package/src/core/graph/styles.js +1 -1
  14. package/src/daemon/server/project-graph-incremental-recomputation.js +7 -8
  15. package/src/daemon/server/shutdown-utils.js +0 -2
  16. package/src/devkit-exports.d.ts +1 -2
  17. package/src/executors/run-commands/run-commands.impl.d.ts +3 -0
  18. package/src/executors/run-commands/run-commands.impl.js +77 -38
  19. package/src/executors/utils/convert-nx-executor.js +1 -4
  20. package/src/generators/utils/project-configuration.js +2 -2
  21. package/src/hasher/hash-task.js +2 -2
  22. package/src/migrations/update-15-1-0/set-project-names.js +2 -2
  23. package/src/plugins/js/index.d.ts +1 -1
  24. package/src/plugins/js/lock-file/lock-file.d.ts +1 -1
  25. package/src/plugins/js/lock-file/npm-parser.d.ts +1 -1
  26. package/src/plugins/js/lock-file/pnpm-parser.d.ts +1 -1
  27. package/src/plugins/js/lock-file/yarn-parser.d.ts +1 -1
  28. package/src/plugins/js/project-graph/build-dependencies/build-dependencies.d.ts +1 -1
  29. package/src/plugins/js/project-graph/build-dependencies/explicit-package-json-dependencies.d.ts +1 -1
  30. package/src/plugins/js/project-graph/build-dependencies/explicit-project-dependencies.d.ts +1 -1
  31. package/src/plugins/js/utils/register.js +3 -1
  32. package/src/plugins/package-json-workspaces/create-nodes.d.ts +2 -2
  33. package/src/plugins/package-json-workspaces/create-nodes.js +31 -24
  34. package/src/plugins/package-json-workspaces/index.d.ts +0 -1
  35. package/src/plugins/package-json-workspaces/index.js +0 -2
  36. package/src/plugins/project-json/build-nodes/package-json-next-to-project-json.d.ts +1 -2
  37. package/src/plugins/project-json/build-nodes/package-json-next-to-project-json.js +0 -1
  38. package/src/plugins/project-json/build-nodes/project-json.d.ts +1 -2
  39. package/src/plugins/project-json/build-nodes/project-json.js +0 -1
  40. package/src/plugins/target-defaults/target-defaults-plugin.d.ts +1 -2
  41. package/src/plugins/target-defaults/target-defaults-plugin.js +0 -1
  42. package/src/project-graph/affected/locators/project-glob-changes.js +3 -3
  43. package/src/project-graph/build-project-graph.d.ts +1 -2
  44. package/src/project-graph/build-project-graph.js +13 -12
  45. package/src/project-graph/file-utils.js +3 -3
  46. package/src/project-graph/project-graph-builder.d.ts +1 -1
  47. package/src/project-graph/project-graph.js +15 -19
  48. package/src/project-graph/utils/normalize-project-nodes.d.ts +1 -1
  49. package/src/project-graph/utils/project-configuration-utils.d.ts +2 -2
  50. package/src/project-graph/utils/project-configuration-utils.js +55 -11
  51. package/src/project-graph/utils/retrieve-workspace-files.d.ts +8 -6
  52. package/src/project-graph/utils/retrieve-workspace-files.js +21 -18
  53. package/src/tasks-runner/task-orchestrator.js +45 -8
  54. package/src/tasks-runner/tasks-schedule.js +3 -3
  55. package/src/tasks-runner/utils.d.ts +7 -6
  56. package/src/tasks-runner/utils.js +11 -7
  57. package/src/utils/logger.d.ts +0 -1
  58. package/src/utils/logger.js +0 -5
  59. package/src/{project-graph/plugins/public-api.d.ts → utils/nx-plugin.d.ts} +41 -7
  60. package/src/utils/nx-plugin.deprecated.d.ts +2 -4
  61. package/src/utils/nx-plugin.deprecated.js +4 -4
  62. package/src/utils/nx-plugin.js +293 -0
  63. package/src/utils/output.js +1 -1
  64. package/src/utils/plugins/plugin-capabilities.d.ts +1 -1
  65. package/src/utils/plugins/plugin-capabilities.js +9 -10
  66. package/src/daemon/server/plugins.d.ts +0 -3
  67. package/src/daemon/server/plugins.js +0 -22
  68. package/src/project-graph/plugins/index.d.ts +0 -2
  69. package/src/project-graph/plugins/index.js +0 -8
  70. package/src/project-graph/plugins/internal-api.d.ts +0 -22
  71. package/src/project-graph/plugins/internal-api.js +0 -64
  72. package/src/project-graph/plugins/messaging.d.ts +0 -94
  73. package/src/project-graph/plugins/messaging.js +0 -23
  74. package/src/project-graph/plugins/plugin-pool.d.ts +0 -3
  75. package/src/project-graph/plugins/plugin-pool.js +0 -189
  76. package/src/project-graph/plugins/plugin-worker.d.ts +0 -1
  77. package/src/project-graph/plugins/plugin-worker.js +0 -101
  78. package/src/project-graph/plugins/public-api.js +0 -4
  79. package/src/project-graph/plugins/utils.d.ts +0 -9
  80. package/src/project-graph/plugins/utils.js +0 -55
  81. package/src/project-graph/plugins/worker-api.d.ts +0 -28
  82. package/src/project-graph/plugins/worker-api.js +0 -195
@@ -12,10 +12,10 @@ const nx_cloud_utils_1 = require("../src/utils/nx-cloud-utils");
12
12
  const nx_json_1 = require("../src/config/nx-json");
13
13
  const workspace_context_1 = require("../src/utils/workspace-context");
14
14
  (async () => {
15
- const start = new Date();
16
15
  try {
17
16
  (0, workspace_context_1.setupWorkspaceContext)(workspace_root_1.workspaceRoot);
18
17
  if (isMainNxPackage() && (0, fileutils_1.fileExists)((0, path_1.join)(workspace_root_1.workspaceRoot, 'nx.json'))) {
18
+ const b = new Date();
19
19
  (0, assert_supported_platform_1.assertSupportedPlatform)();
20
20
  try {
21
21
  await client_1.daemonClient.stop();
@@ -34,6 +34,10 @@ const workspace_context_1 = require("../src/utils/workspace-context");
34
34
  }
35
35
  });
36
36
  }));
37
+ if (process.env.NX_VERBOSE_LOGGING === 'true') {
38
+ const a = new Date();
39
+ console.log(`Nx postinstall steps took ${a.getTime() - b.getTime()}ms`);
40
+ }
37
41
  }
38
42
  }
39
43
  catch (e) {
@@ -41,12 +45,6 @@ const workspace_context_1 = require("../src/utils/workspace-context");
41
45
  console.log(e);
42
46
  }
43
47
  }
44
- finally {
45
- if (process.env.NX_VERBOSE_LOGGING === 'true') {
46
- const end = new Date();
47
- console.log(`Nx postinstall steps took ${end.getTime() - start.getTime()}ms`);
48
- }
49
- }
50
48
  })();
51
49
  function isMainNxPackage() {
52
50
  const mainNxPath = require.resolve('nx', {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nx",
3
- "version": "18.1.0-canary.20240309-235ca8c",
3
+ "version": "18.1.0-canary.20240313-81df848",
4
4
  "private": false,
5
5
  "description": "The core Nx plugin contains the core functionality of Nx like the project graph, nx commands and task orchestration.",
6
6
  "repository": {
@@ -66,7 +66,7 @@
66
66
  "yargs-parser": "21.1.1",
67
67
  "node-machine-id": "1.1.12",
68
68
  "ora": "5.3.0",
69
- "@nrwl/tao": "18.1.0-canary.20240309-235ca8c"
69
+ "@nrwl/tao": "18.1.0-canary.20240313-81df848"
70
70
  },
71
71
  "peerDependencies": {
72
72
  "@swc-node/register": "^1.8.0",
@@ -81,16 +81,16 @@
81
81
  }
82
82
  },
83
83
  "optionalDependencies": {
84
- "@nx/nx-darwin-x64": "18.1.0-canary.20240309-235ca8c",
85
- "@nx/nx-darwin-arm64": "18.1.0-canary.20240309-235ca8c",
86
- "@nx/nx-linux-x64-gnu": "18.1.0-canary.20240309-235ca8c",
87
- "@nx/nx-linux-x64-musl": "18.1.0-canary.20240309-235ca8c",
88
- "@nx/nx-win32-x64-msvc": "18.1.0-canary.20240309-235ca8c",
89
- "@nx/nx-linux-arm64-gnu": "18.1.0-canary.20240309-235ca8c",
90
- "@nx/nx-linux-arm64-musl": "18.1.0-canary.20240309-235ca8c",
91
- "@nx/nx-linux-arm-gnueabihf": "18.1.0-canary.20240309-235ca8c",
92
- "@nx/nx-win32-arm64-msvc": "18.1.0-canary.20240309-235ca8c",
93
- "@nx/nx-freebsd-x64": "18.1.0-canary.20240309-235ca8c"
84
+ "@nx/nx-darwin-x64": "18.1.0-canary.20240313-81df848",
85
+ "@nx/nx-darwin-arm64": "18.1.0-canary.20240313-81df848",
86
+ "@nx/nx-linux-x64-gnu": "18.1.0-canary.20240313-81df848",
87
+ "@nx/nx-linux-x64-musl": "18.1.0-canary.20240313-81df848",
88
+ "@nx/nx-win32-x64-msvc": "18.1.0-canary.20240313-81df848",
89
+ "@nx/nx-linux-arm64-gnu": "18.1.0-canary.20240313-81df848",
90
+ "@nx/nx-linux-arm64-musl": "18.1.0-canary.20240313-81df848",
91
+ "@nx/nx-linux-arm-gnueabihf": "18.1.0-canary.20240313-81df848",
92
+ "@nx/nx-win32-arm64-msvc": "18.1.0-canary.20240313-81df848",
93
+ "@nx/nx-freebsd-x64": "18.1.0-canary.20240313-81df848"
94
94
  },
95
95
  "nx-migrations": {
96
96
  "migrations": "./migrations.json",
@@ -1,8 +1,7 @@
1
1
  import { ProjectsConfigurations } from '../config/workspace-json-project-json';
2
- import { NxPluginV2 } from '../project-graph/plugins';
2
+ import { NxPluginV2 } from '../utils/nx-plugin';
3
3
  export declare const NX_ANGULAR_JSON_PLUGIN_NAME = "nx-angular-json-plugin";
4
4
  export declare const NxAngularJsonPlugin: NxPluginV2;
5
- export default NxAngularJsonPlugin;
6
5
  export declare function shouldMergeAngularProjects(root: string, includeProjectsFromAngularJson: boolean): boolean;
7
6
  export declare function isAngularPluginInstalled(): boolean;
8
7
  export declare function toNewFormat(w: any): ProjectsConfigurations;
@@ -14,7 +14,6 @@ exports.NxAngularJsonPlugin = {
14
14
  }),
15
15
  ],
16
16
  };
17
- exports.default = exports.NxAngularJsonPlugin;
18
17
  function shouldMergeAngularProjects(root, includeProjectsFromAngularJson) {
19
18
  if ((0, fs_1.existsSync)(path.join(root, 'angular.json')) &&
20
19
  // Include projects from angular.json if explicitly required.
@@ -19,7 +19,7 @@ const package_json_1 = require("../utils/package-json");
19
19
  const package_manager_1 = require("../utils/package-manager");
20
20
  const angular_json_1 = require("./angular-json");
21
21
  const executor_utils_1 = require("../command-line/run/executor-utils");
22
- const plugins_1 = require("../project-graph/plugins");
22
+ const nx_plugin_1 = require("../utils/nx-plugin");
23
23
  const schema_utils_1 = require("../config/schema-utils");
24
24
  async function createBuilderContext(builderInfo, context) {
25
25
  require('./compat');
@@ -146,7 +146,7 @@ function createNodeModulesEngineHost(resolvePaths, projects) {
146
146
  collectionFilePath = require.resolve(name, { paths });
147
147
  }
148
148
  else {
149
- const { json: { generators, schematics }, path: packageJsonPath, } = (0, plugins_1.readPluginPackageJson)(name, projects, paths);
149
+ const { json: { generators, schematics }, path: packageJsonPath, } = (0, nx_plugin_1.readPluginPackageJson)(name, projects, paths);
150
150
  if (!schematics && !generators) {
151
151
  throw new Error(`The "${name}" package does not support Nx generators or Angular Devkit schematics.`);
152
152
  }
@@ -802,7 +802,7 @@ async function getWrappedWorkspaceNodeModulesArchitectHost(workspace, root, proj
802
802
  };
803
803
  }
804
804
  readExecutorsJson(nodeModule, builder) {
805
- const { json: packageJson, path: packageJsonPath } = (0, plugins_1.readPluginPackageJson)(nodeModule, this.projects, this.root ? [this.root, __dirname] : [__dirname]);
805
+ const { json: packageJson, path: packageJsonPath } = (0, nx_plugin_1.readPluginPackageJson)(nodeModule, this.projects, this.root ? [this.root, __dirname] : [__dirname]);
806
806
  const executorsFile = packageJson.executors ?? packageJson.builders;
807
807
  if (!executorsFile) {
808
808
  throw new Error(`The "${nodeModule}" package does not support Nx executors or Angular Devkit Builders.`);
@@ -4,7 +4,7 @@ exports.readGeneratorsJson = exports.getGeneratorInformation = void 0;
4
4
  const path_1 = require("path");
5
5
  const schema_utils_1 = require("../../config/schema-utils");
6
6
  const fileutils_1 = require("../../utils/fileutils");
7
- const plugins_1 = require("../../project-graph/plugins");
7
+ const nx_plugin_1 = require("../../utils/nx-plugin");
8
8
  function getGeneratorInformation(collectionName, generatorName, root, projects) {
9
9
  try {
10
10
  const { generatorsFilePath, generatorsJson, resolvedCollectionName, normalizedGeneratorName, } = readGeneratorsJson(collectionName, generatorName, root, projects);
@@ -48,7 +48,7 @@ function readGeneratorsJson(collectionName, generator, root, projects) {
48
48
  });
49
49
  }
50
50
  else {
51
- const { json: packageJson, path: packageJsonPath } = (0, plugins_1.readPluginPackageJson)(collectionName, projects, root ? [root, __dirname] : [__dirname]);
51
+ const { json: packageJson, path: packageJsonPath } = (0, nx_plugin_1.readPluginPackageJson)(collectionName, projects, root ? [root, __dirname] : [__dirname]);
52
52
  const generatorsFile = packageJson.generators ?? packageJson.schematics;
53
53
  if (!generatorsFile) {
54
54
  throw new Error(`The "${collectionName}" package does not support Nx generators.`);
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getExecutorInformation = exports.normalizeExecutorSchema = void 0;
4
4
  const path_1 = require("path");
5
- const plugins_1 = require("../../project-graph/plugins");
5
+ const nx_plugin_1 = require("../../utils/nx-plugin");
6
6
  const fileutils_1 = require("../../utils/fileutils");
7
7
  const schema_utils_1 = require("../../config/schema-utils");
8
8
  const installation_directory_1 = require("../../utils/installation-directory");
@@ -55,7 +55,7 @@ function getExecutorInformation(nodeModule, executor, root, projects) {
55
55
  }
56
56
  exports.getExecutorInformation = getExecutorInformation;
57
57
  function readExecutorJson(nodeModule, executor, root, projects) {
58
- const { json: packageJson, path: packageJsonPath } = (0, plugins_1.readPluginPackageJson)(nodeModule, projects, root
58
+ const { json: packageJson, path: packageJsonPath } = (0, nx_plugin_1.readPluginPackageJson)(nodeModule, projects, root
59
59
  ? [root, __dirname, process.cwd(), ...(0, installation_directory_1.getNxRequirePaths)()]
60
60
  : [__dirname, process.cwd(), ...(0, installation_directory_1.getNxRequirePaths)()]);
61
61
  const executorsFile = packageJson.executors ?? packageJson.builders;
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.resolveSchema = exports.resolveImplementation = exports.getImplementationFactory = void 0;
4
4
  const fs_1 = require("fs");
5
5
  const path_1 = require("path");
6
- const plugins_1 = require("../project-graph/plugins");
6
+ const nx_plugin_1 = require("../utils/nx-plugin");
7
7
  /**
8
8
  * This function is used to get the implementation factory of an executor or generator.
9
9
  * @param implementation path to the implementation
@@ -15,7 +15,7 @@ function getImplementationFactory(implementation, directory) {
15
15
  return () => {
16
16
  const modulePath = resolveImplementation(implementationModulePath, directory);
17
17
  if ((0, path_1.extname)(modulePath) === '.ts') {
18
- (0, plugins_1.registerPluginTSTranspiler)();
18
+ (0, nx_plugin_1.registerPluginTSTranspiler)();
19
19
  }
20
20
  const module = require(modulePath);
21
21
  return implementationExportName
@@ -704,6 +704,57 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
704
704
  SOFTWARE.
705
705
 
706
706
 
707
+ regenerator-runtime
708
+ MIT
709
+ MIT License
710
+
711
+ Copyright (c) 2014-present, Facebook, Inc.
712
+
713
+ Permission is hereby granted, free of charge, to any person obtaining a copy
714
+ of this software and associated documentation files (the "Software"), to deal
715
+ in the Software without restriction, including without limitation the rights
716
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
717
+ copies of the Software, and to permit persons to whom the Software is
718
+ furnished to do so, subject to the following conditions:
719
+
720
+ The above copyright notice and this permission notice shall be included in all
721
+ copies or substantial portions of the Software.
722
+
723
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
724
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
725
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
726
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
727
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
728
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
729
+ SOFTWARE.
730
+
731
+
732
+ tabbable
733
+ MIT
734
+ The MIT License (MIT)
735
+
736
+ Copyright (c) 2015 David Clark
737
+
738
+ Permission is hereby granted, free of charge, to any person obtaining a copy
739
+ of this software and associated documentation files (the "Software"), to deal
740
+ in the Software without restriction, including without limitation the rights
741
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
742
+ copies of the Software, and to permit persons to whom the Software is
743
+ furnished to do so, subject to the following conditions:
744
+
745
+ The above copyright notice and this permission notice shall be included in all
746
+ copies or substantial portions of the Software.
747
+
748
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
749
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
750
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
751
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
752
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
753
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
754
+ SOFTWARE.
755
+
756
+
757
+
707
758
  toggle-selection
708
759
  MIT
709
760