nx 18.3.0-canary.20240416-2ee9650 → 18.3.1

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nx",
3
- "version": "18.3.0-canary.20240416-2ee9650",
3
+ "version": "18.3.1",
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.3.0-canary.20240416-2ee9650"
69
+ "@nrwl/tao": "18.3.1"
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.3.0-canary.20240416-2ee9650",
85
- "@nx/nx-darwin-arm64": "18.3.0-canary.20240416-2ee9650",
86
- "@nx/nx-linux-x64-gnu": "18.3.0-canary.20240416-2ee9650",
87
- "@nx/nx-linux-x64-musl": "18.3.0-canary.20240416-2ee9650",
88
- "@nx/nx-win32-x64-msvc": "18.3.0-canary.20240416-2ee9650",
89
- "@nx/nx-linux-arm64-gnu": "18.3.0-canary.20240416-2ee9650",
90
- "@nx/nx-linux-arm64-musl": "18.3.0-canary.20240416-2ee9650",
91
- "@nx/nx-linux-arm-gnueabihf": "18.3.0-canary.20240416-2ee9650",
92
- "@nx/nx-win32-arm64-msvc": "18.3.0-canary.20240416-2ee9650",
93
- "@nx/nx-freebsd-x64": "18.3.0-canary.20240416-2ee9650"
84
+ "@nx/nx-darwin-x64": "18.3.1",
85
+ "@nx/nx-darwin-arm64": "18.3.1",
86
+ "@nx/nx-linux-x64-gnu": "18.3.1",
87
+ "@nx/nx-linux-x64-musl": "18.3.1",
88
+ "@nx/nx-win32-x64-msvc": "18.3.1",
89
+ "@nx/nx-linux-arm64-gnu": "18.3.1",
90
+ "@nx/nx-linux-arm64-musl": "18.3.1",
91
+ "@nx/nx-linux-arm-gnueabihf": "18.3.1",
92
+ "@nx/nx-win32-arm64-msvc": "18.3.1",
93
+ "@nx/nx-freebsd-x64": "18.3.1"
94
94
  },
95
95
  "nx-migrations": {
96
96
  "migrations": "./migrations.json",
@@ -7,7 +7,6 @@ const ignore_1 = require("ignore");
7
7
  const path_1 = require("path");
8
8
  const fileutils_1 = require("../../../utils/fileutils");
9
9
  const output_1 = require("../../../utils/output");
10
- const package_manager_1 = require("../../../utils/package-manager");
11
10
  const utils_1 = require("./utils");
12
11
  const connect_to_nx_cloud_1 = require("../../connect/connect-to-nx-cloud");
13
12
  async function addNxToMonorepo(options) {
@@ -61,11 +60,6 @@ async function addNxToMonorepo(options) {
61
60
  : false);
62
61
  }
63
62
  (0, utils_1.createNxJsonFile)(repoRoot, targetDefaults, cacheableOperations, scriptOutputs);
64
- if (!options.legacy) {
65
- packageJsonFiles.forEach((packageJsonPath) => {
66
- (0, utils_1.markPackageJsonAsNxProject)((0, path_1.join)(repoRoot, packageJsonPath));
67
- });
68
- }
69
63
  (0, utils_1.updateGitIgnore)(repoRoot);
70
64
  (0, utils_1.addDepsToPackageJson)(repoRoot);
71
65
  output_1.output.log({ title: '📦 Installing dependencies' });
@@ -74,15 +68,6 @@ async function addNxToMonorepo(options) {
74
68
  output_1.output.log({ title: '🛠️ Setting up Nx Cloud' });
75
69
  (0, utils_1.initCloud)(repoRoot, 'nx-init-monorepo');
76
70
  }
77
- const pmc = (0, package_manager_1.getPackageManagerCommand)();
78
- (0, utils_1.printFinalMessage)({
79
- learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-monorepo',
80
- bodyLines: [
81
- `- Run "${pmc.exec} nx run-many --target=build" to run the build script for every project in the monorepo.`,
82
- '- Run it again to replay the cached computation.',
83
- `- Run "${pmc.exec} nx graph" to see the structure of the monorepo.`,
84
- ],
85
- });
86
71
  }
87
72
  exports.addNxToMonorepo = addNxToMonorepo;
88
73
  // scanning package.json files
@@ -91,9 +91,6 @@ async function addNxToNest(options, packageJson) {
91
91
  output_1.output.log({ title: '🛠️ Setting up Nx Cloud' });
92
92
  (0, utils_1.initCloud)(repoRoot, 'nx-init-nest');
93
93
  }
94
- (0, utils_1.printFinalMessage)({
95
- learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-monorepo',
96
- });
97
94
  }
98
95
  exports.addNxToNest = addNxToNest;
99
96
  function addNestPluginToPackageJson(repoRoot) {
@@ -122,7 +119,6 @@ function createProjectJson(repoRoot, packageJson, nestCLIOptions) {
122
119
  buildTarget: `${packageName}:build`,
123
120
  },
124
121
  };
125
- console.log(nestCLIOptions);
126
122
  if (nestCLIOptions.webpackOptions) {
127
123
  json.targets['build'] = {
128
124
  executor: '@nx/webpack:webpack',
@@ -65,8 +65,5 @@ async function addNxToNpmRepo(options) {
65
65
  output_1.output.log({ title: '🛠️ Setting up Nx Cloud' });
66
66
  (0, utils_1.initCloud)(repoRoot, 'nx-init-npm-repo');
67
67
  }
68
- (0, utils_1.printFinalMessage)({
69
- learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-existing-project',
70
- });
71
68
  }
72
69
  exports.addNxToNpmRepo = addNxToNpmRepo;
@@ -46,12 +46,6 @@ async function addNxToAngularCliRepo(options) {
46
46
  output_1.output.log({ title: '🛠️ Setting up Nx Cloud' });
47
47
  (0, utils_1.initCloud)(repoRoot, 'nx-init-angular');
48
48
  }
49
- (0, utils_1.printFinalMessage)({
50
- learnMoreLink: 'https://nx.dev/recipes/angular/migration/angular',
51
- bodyLines: [
52
- '- Execute "npx nx build" twice to see the computation caching in action.',
53
- ],
54
- });
55
49
  }
56
50
  exports.addNxToAngularCliRepo = addNxToAngularCliRepo;
57
51
  async function collectCacheableOperations(options) {
@@ -86,12 +86,6 @@ async function getLegacyMigrationFunctionIfApplicable(repoRoot, options) {
86
86
  output_1.output.log({ title: '🛠️ Setting up Nx Cloud' });
87
87
  (0, utils_1.initCloud)(repoRoot, 'nx-init-angular');
88
88
  }
89
- (0, utils_1.printFinalMessage)({
90
- learnMoreLink: 'https://nx.dev/recipes/angular/migration/angular',
91
- bodyLines: [
92
- '- Execute "npx nx build" twice to see the computation caching in action.',
93
- ],
94
- });
95
89
  };
96
90
  }
97
91
  exports.getLegacyMigrationFunctionIfApplicable = getLegacyMigrationFunctionIfApplicable;
@@ -7,7 +7,6 @@ const path_1 = require("path");
7
7
  const fileutils_1 = require("../../../../utils/fileutils");
8
8
  const output_1 = require("../../../../utils/output");
9
9
  const package_manager_1 = require("../../../../utils/package-manager");
10
- const utils_1 = require("../utils");
11
10
  const check_for_custom_webpack_setup_1 = require("./check-for-custom-webpack-setup");
12
11
  const check_for_uncommitted_changes_1 = require("./check-for-uncommitted-changes");
13
12
  const clean_up_files_1 = require("./clean-up-files");
@@ -96,24 +95,6 @@ async function reorgnizeWorkspaceStructure(options) {
96
95
  output_1.output.log({ title: '🙂 Please be patient, one final step remaining!' });
97
96
  output_1.output.log({ title: '📦 Installing dependencies' });
98
97
  installDependencies(options);
99
- const buildCommand = options.integrated
100
- ? `npx nx build ${options.reactAppName}`
101
- : 'npm run build';
102
- (0, utils_1.printFinalMessage)({
103
- learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-existing-project',
104
- bodyLines: [
105
- `- Execute "${buildCommand}" twice to see the computation caching in action.`,
106
- ],
107
- });
108
- output_1.output.note({
109
- title: 'First time using Nx? Check out this interactive Nx tutorial.',
110
- bodyLines: [
111
- `https://nx.dev/react-tutorial/1-code-generation`,
112
- ` `,
113
- `Prefer watching videos? Check out this free Nx course on Egghead.io.`,
114
- `https://egghead.io/playlists/scale-react-development-with-nx-4038`,
115
- ],
116
- });
117
98
  if (options.isVite) {
118
99
  const indexPath = options.isStandalone
119
100
  ? 'index.html'
@@ -10,8 +10,7 @@ export declare function initCloud(repoRoot: string, installationSource: 'nx-init
10
10
  export declare function addVsCodeRecommendedExtensions(repoRoot: string, extensions: string[]): void;
11
11
  export declare function markRootPackageJsonAsNxProjectLegacy(repoRoot: string, cacheableScripts: string[], pmc: PackageManagerCommands): void;
12
12
  export declare function markPackageJsonAsNxProject(packageJsonPath: string): void;
13
- export declare function printFinalMessage({ learnMoreLink, bodyLines, }: {
13
+ export declare function printFinalMessage({ learnMoreLink, }: {
14
14
  learnMoreLink?: string;
15
- bodyLines?: string[];
16
15
  }): void;
17
16
  export declare function isMonorepo(packageJson: PackageJson): boolean;
@@ -163,13 +163,13 @@ function markPackageJsonAsNxProject(packageJsonPath) {
163
163
  (0, fileutils_1.writeJsonFile)(packageJsonPath, json);
164
164
  }
165
165
  exports.markPackageJsonAsNxProject = markPackageJsonAsNxProject;
166
- function printFinalMessage({ learnMoreLink, bodyLines, }) {
167
- const normalizedBodyLines = (bodyLines ?? []).map((l) => l.startsWith('- ') ? l : `- ${l}`);
166
+ function printFinalMessage({ learnMoreLink, }) {
167
+ const pmc = (0, package_manager_1.getPackageManagerCommand)();
168
168
  output_1.output.success({
169
169
  title: '🎉 Done!',
170
170
  bodyLines: [
171
- '- Enabled computation caching!',
172
- ...normalizedBodyLines,
171
+ `- Run "${pmc.exec} nx run-many -t build" to run the build target for every project in the workspace. Run it again to replay the cached computation. https://nx.dev/features/cache-task-results`,
172
+ `- Run "${pmc.exec} nx graph" to see the graph of projects and tasks in your workspace. https://nx.dev/core-features/explore-graph`,
173
173
  learnMoreLink ? `- Learn more at ${learnMoreLink}.` : undefined,
174
174
  ].filter(Boolean),
175
175
  });
@@ -29,18 +29,38 @@ async function initHandler(options) {
29
29
  const packageJson = (0, fileutils_1.readJsonFile)('package.json');
30
30
  if ((0, fs_1.existsSync)('angular.json')) {
31
31
  await (0, angular_1.addNxToAngularCliRepo)(options);
32
+ (0, utils_1.printFinalMessage)({
33
+ learnMoreLink: 'https://nx.dev/recipes/angular/migration/angular',
34
+ });
35
+ return;
32
36
  }
33
37
  else if (isCRA(packageJson)) {
34
38
  await (0, react_1.addNxToCraRepo)(options);
39
+ (0, utils_1.printFinalMessage)({
40
+ learnMoreLink: options.integrated
41
+ ? 'https://nx.dev/getting-started/tutorials/react-monorepo-tutorial'
42
+ : 'https://nx.dev/getting-started/tutorials/react-standalone-tutorial',
43
+ });
44
+ return;
35
45
  }
36
46
  else if (isNestCLI(packageJson)) {
37
47
  await (0, add_nx_to_nest_1.addNxToNest)(options, packageJson);
48
+ (0, utils_1.printFinalMessage)({
49
+ learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-monorepo',
50
+ });
51
+ return;
38
52
  }
39
53
  else if ((0, utils_1.isMonorepo)(packageJson)) {
40
54
  await (0, add_nx_to_monorepo_1.addNxToMonorepo)({ ...options, legacy: true });
55
+ (0, utils_1.printFinalMessage)({
56
+ learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-monorepo',
57
+ });
41
58
  }
42
59
  else {
43
60
  await (0, add_nx_to_npm_repo_1.addNxToNpmRepo)({ ...options, legacy: true });
61
+ (0, utils_1.printFinalMessage)({
62
+ learnMoreLink: 'https://nx.dev/recipes/adopting-nx/adding-to-existing-project',
63
+ });
44
64
  }
45
65
  }
46
66
  else {
@@ -47,6 +47,9 @@ async function initHandler(options) {
47
47
  ...options,
48
48
  integrated: !!options.integrated,
49
49
  });
50
+ (0, utils_1.printFinalMessage)({
51
+ learnMoreLink: 'https://nx.dev/recipes/angular/migration/angular',
52
+ });
50
53
  return;
51
54
  }
52
55
  output_1.output.log({ title: '🧐 Checking dependencies' });
@@ -64,6 +67,9 @@ async function initHandler(options) {
64
67
  nxCloud: false,
65
68
  });
66
69
  }
70
+ const learnMoreLink = (0, utils_1.isMonorepo)(packageJson)
71
+ ? 'https://nx.dev/getting-started/tutorials/npm-workspaces-tutorial'
72
+ : 'https://nx.dev/recipes/adopting-nx/adding-to-existing-project';
67
73
  const useNxCloud = options.nxCloud ??
68
74
  (options.interactive ? await (0, connect_to_nx_cloud_1.connectExistingRepoToNxCloudPrompt)() : false);
69
75
  const repoRoot = process.cwd();
@@ -89,12 +95,8 @@ async function initHandler(options) {
89
95
  cwd: repoRoot,
90
96
  });
91
97
  }
92
- output_1.output.log({
93
- title: '👀 Explore Your Workspace',
94
- bodyLines: [
95
- `Run "nx graph" to show the graph of the workspace. It will show tasks that you can run with Nx.`,
96
- `Read this guide on exploring your workspace: https://nx.dev/core-features/explore-graph`,
97
- ],
98
+ (0, utils_1.printFinalMessage)({
99
+ learnMoreLink,
98
100
  });
99
101
  }
100
102
  exports.initHandler = initHandler;
@@ -212,29 +212,6 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
212
212
  SOFTWARE.
213
213
 
214
214
 
215
- core-js
216
- MIT
217
- Copyright (c) 2014-2024 Denis Pushkarev
218
-
219
- Permission is hereby granted, free of charge, to any person obtaining a copy
220
- of this software and associated documentation files (the "Software"), to deal
221
- in the Software without restriction, including without limitation the rights
222
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
223
- copies of the Software, and to permit persons to whom the Software is
224
- furnished to do so, subject to the following conditions:
225
-
226
- The above copyright notice and this permission notice shall be included in
227
- all copies or substantial portions of the Software.
228
-
229
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
230
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
231
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
232
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
233
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
234
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
235
- THE SOFTWARE.
236
-
237
-
238
215
  cytoscape
239
216
  MIT
240
217
  Copyright (c) 2016-2022, The Cytoscape Consortium.
@@ -704,6 +681,32 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
704
681
  SOFTWARE.
705
682
 
706
683
 
684
+ tabbable
685
+ MIT
686
+ The MIT License (MIT)
687
+
688
+ Copyright (c) 2015 David Clark
689
+
690
+ Permission is hereby granted, free of charge, to any person obtaining a copy
691
+ of this software and associated documentation files (the "Software"), to deal
692
+ in the Software without restriction, including without limitation the rights
693
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
694
+ copies of the Software, and to permit persons to whom the Software is
695
+ furnished to do so, subject to the following conditions:
696
+
697
+ The above copyright notice and this permission notice shall be included in all
698
+ copies or substantial portions of the Software.
699
+
700
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
701
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
702
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
703
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
704
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
705
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
706
+ SOFTWARE.
707
+
708
+
709
+
707
710
  toggle-selection
708
711
  MIT
709
712