nx 20.4.0-canary.20250124-45847a6 → 20.4.0-rc.0

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 (36) hide show
  1. package/package.json +11 -11
  2. package/src/command-line/release/config/conventional-commits.js +7 -0
  3. package/src/command-line/release/publish.js +11 -0
  4. package/src/command-line/release/utils/git.js +6 -1
  5. package/src/core/graph/main.js +1 -1
  6. package/src/core/graph/styles.js +1 -1
  7. package/src/daemon/client/client.d.ts +3 -0
  8. package/src/daemon/client/client.js +15 -0
  9. package/src/daemon/message-types/run-tasks-execution-hooks.d.ts +13 -0
  10. package/src/daemon/message-types/run-tasks-execution-hooks.js +19 -0
  11. package/src/daemon/server/handle-tasks-execution-hooks.d.ts +19 -0
  12. package/src/daemon/server/handle-tasks-execution-hooks.js +35 -0
  13. package/src/daemon/server/server.js +8 -0
  14. package/src/devkit-exports.d.ts +6 -2
  15. package/src/native/nx.wasm32-wasi.wasm +0 -0
  16. package/src/plugins/js/project-graph/build-dependencies/target-project-locator.js +1 -4
  17. package/src/plugins/js/utils/packages.js +2 -16
  18. package/src/project-graph/plugins/get-plugins.js +2 -17
  19. package/src/project-graph/plugins/isolation/enabled.d.ts +1 -0
  20. package/src/project-graph/plugins/isolation/enabled.js +19 -0
  21. package/src/project-graph/plugins/isolation/messaging.d.ts +46 -7
  22. package/src/project-graph/plugins/isolation/messaging.js +5 -1
  23. package/src/project-graph/plugins/isolation/plugin-pool.js +46 -0
  24. package/src/project-graph/plugins/isolation/plugin-worker.js +40 -0
  25. package/src/project-graph/plugins/load-resolved-plugin.js +4 -1
  26. package/src/project-graph/plugins/loaded-nx-plugin.d.ts +3 -5
  27. package/src/project-graph/plugins/loaded-nx-plugin.js +27 -0
  28. package/src/project-graph/plugins/public-api.d.ts +26 -6
  29. package/src/project-graph/plugins/tasks-execution-hooks.d.ts +3 -0
  30. package/src/project-graph/plugins/tasks-execution-hooks.js +65 -0
  31. package/src/project-graph/utils/retrieve-workspace-files.js +1 -1
  32. package/src/tasks-runner/forked-process-task-runner.js +8 -30
  33. package/src/tasks-runner/life-cycle.d.ts +7 -0
  34. package/src/tasks-runner/run-command.d.ts +2 -4
  35. package/src/tasks-runner/run-command.js +18 -2
  36. package/src/tasks-runner/task-orchestrator.js +6 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nx",
3
- "version": "20.4.0-canary.20250124-45847a6",
3
+ "version": "20.4.0-rc.0",
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": {
@@ -82,16 +82,16 @@
82
82
  }
83
83
  },
84
84
  "optionalDependencies": {
85
- "@nx/nx-darwin-arm64": "20.4.0-canary.20250124-45847a6",
86
- "@nx/nx-darwin-x64": "20.4.0-canary.20250124-45847a6",
87
- "@nx/nx-freebsd-x64": "20.4.0-canary.20250124-45847a6",
88
- "@nx/nx-linux-arm-gnueabihf": "20.4.0-canary.20250124-45847a6",
89
- "@nx/nx-linux-arm64-gnu": "20.4.0-canary.20250124-45847a6",
90
- "@nx/nx-linux-arm64-musl": "20.4.0-canary.20250124-45847a6",
91
- "@nx/nx-linux-x64-gnu": "20.4.0-canary.20250124-45847a6",
92
- "@nx/nx-linux-x64-musl": "20.4.0-canary.20250124-45847a6",
93
- "@nx/nx-win32-arm64-msvc": "20.4.0-canary.20250124-45847a6",
94
- "@nx/nx-win32-x64-msvc": "20.4.0-canary.20250124-45847a6"
85
+ "@nx/nx-darwin-arm64": "20.4.0-rc.0",
86
+ "@nx/nx-darwin-x64": "20.4.0-rc.0",
87
+ "@nx/nx-freebsd-x64": "20.4.0-rc.0",
88
+ "@nx/nx-linux-arm-gnueabihf": "20.4.0-rc.0",
89
+ "@nx/nx-linux-arm64-gnu": "20.4.0-rc.0",
90
+ "@nx/nx-linux-arm64-musl": "20.4.0-rc.0",
91
+ "@nx/nx-linux-x64-gnu": "20.4.0-rc.0",
92
+ "@nx/nx-linux-x64-musl": "20.4.0-rc.0",
93
+ "@nx/nx-win32-arm64-msvc": "20.4.0-rc.0",
94
+ "@nx/nx-win32-x64-msvc": "20.4.0-rc.0"
95
95
  },
96
96
  "nx-migrations": {
97
97
  "migrations": "./migrations.json",
@@ -94,5 +94,12 @@ exports.DEFAULT_CONVENTIONAL_COMMITS_CONFIG = {
94
94
  hidden: true,
95
95
  },
96
96
  },
97
+ __INVALID__: {
98
+ semverBump: 'none',
99
+ changelog: {
100
+ title: 'Invalid based on conventional commits specification',
101
+ hidden: true,
102
+ },
103
+ },
97
104
  },
98
105
  };
@@ -15,6 +15,8 @@ const config_1 = require("./config/config");
15
15
  const deep_merge_json_1 = require("./config/deep-merge-json");
16
16
  const filter_release_groups_1 = require("./config/filter-release-groups");
17
17
  const print_config_1 = require("./utils/print-config");
18
+ const workspace_root_1 = require("../../utils/workspace-root");
19
+ const tasks_execution_hooks_1 = require("../../project-graph/plugins/tasks-execution-hooks");
18
20
  const releasePublishCLIHandler = (args) => (0, handle_errors_1.handleErrors)(args.verbose, async () => {
19
21
  const publishProjectsResult = await createAPI({})(args);
20
22
  // If all projects are published successfully, return 0, otherwise return 1
@@ -154,6 +156,10 @@ async function runPublishOnProjects(args, projectGraph, nxJson, projectNames, ex
154
156
  `This is usually caused by not having an appropriate plugin, such as "@nx/js" installed, which will add the appropriate "${requiredTargetName}" target for you automatically.`,
155
157
  ].join('\n')}\n`);
156
158
  }
159
+ await (0, tasks_execution_hooks_1.runPreTasksExecution)({
160
+ workspaceRoot: workspace_root_1.workspaceRoot,
161
+ nxJsonConfiguration: nxJson,
162
+ });
157
163
  /**
158
164
  * Run the relevant nx-release-publish executor on each of the selected projects.
159
165
  */
@@ -170,5 +176,10 @@ async function runPublishOnProjects(args, projectGraph, nxJson, projectNames, ex
170
176
  code: taskData.code,
171
177
  };
172
178
  }
179
+ await (0, tasks_execution_hooks_1.runPostTasksExecution)({
180
+ taskResults: commandResults,
181
+ workspaceRoot: workspace_root_1.workspaceRoot,
182
+ nxJsonConfiguration: nxJson,
183
+ });
173
184
  return publishProjectsResult;
174
185
  }
@@ -292,7 +292,12 @@ function parseCommits(commits) {
292
292
  function parseConventionalCommitsMessage(message) {
293
293
  const match = message.match(ConventionalCommitRegex);
294
294
  if (!match) {
295
- return null;
295
+ return {
296
+ type: '__INVALID__',
297
+ scope: '',
298
+ description: message,
299
+ breaking: false,
300
+ };
296
301
  }
297
302
  return {
298
303
  type: match.groups.type || '',