nx 20.5.0-rc.2 → 20.5.0-rc.4

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": "20.5.0-rc.2",
3
+ "version": "20.5.0-rc.4",
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.5.0-rc.2",
86
- "@nx/nx-darwin-x64": "20.5.0-rc.2",
87
- "@nx/nx-freebsd-x64": "20.5.0-rc.2",
88
- "@nx/nx-linux-arm-gnueabihf": "20.5.0-rc.2",
89
- "@nx/nx-linux-arm64-gnu": "20.5.0-rc.2",
90
- "@nx/nx-linux-arm64-musl": "20.5.0-rc.2",
91
- "@nx/nx-linux-x64-gnu": "20.5.0-rc.2",
92
- "@nx/nx-linux-x64-musl": "20.5.0-rc.2",
93
- "@nx/nx-win32-arm64-msvc": "20.5.0-rc.2",
94
- "@nx/nx-win32-x64-msvc": "20.5.0-rc.2"
85
+ "@nx/nx-darwin-arm64": "20.5.0-rc.4",
86
+ "@nx/nx-darwin-x64": "20.5.0-rc.4",
87
+ "@nx/nx-freebsd-x64": "20.5.0-rc.4",
88
+ "@nx/nx-linux-arm-gnueabihf": "20.5.0-rc.4",
89
+ "@nx/nx-linux-arm64-gnu": "20.5.0-rc.4",
90
+ "@nx/nx-linux-arm64-musl": "20.5.0-rc.4",
91
+ "@nx/nx-linux-x64-gnu": "20.5.0-rc.4",
92
+ "@nx/nx-linux-x64-musl": "20.5.0-rc.4",
93
+ "@nx/nx-win32-arm64-msvc": "20.5.0-rc.4",
94
+ "@nx/nx-win32-x64-msvc": "20.5.0-rc.4"
95
95
  },
96
96
  "nx-migrations": {
97
97
  "migrations": "./migrations.json",
@@ -12,9 +12,9 @@ const package_manager_1 = require("../../utils/package-manager");
12
12
  const output_1 = require("../../utils/output");
13
13
  const workspace_root_1 = require("../../utils/workspace-root");
14
14
  const utils_1 = require("./implementation/utils");
15
- const plugins_1 = require("../../utils/plugins");
16
15
  const angular_json_1 = require("../../adapter/angular-json");
17
16
  const error_types_1 = require("../../project-graph/error-types");
17
+ const generator_utils_1 = require("../generate/generator-utils");
18
18
  function runPackageManagerInstallPlugins(repoRoot, pmc = (0, package_manager_1.getPackageManagerCommand)(), plugins) {
19
19
  if (plugins.length === 0) {
20
20
  return;
@@ -32,23 +32,21 @@ function runPackageManagerInstallPlugins(repoRoot, pmc = (0, package_manager_1.g
32
32
  * @returns void
33
33
  */
34
34
  async function installPlugin(plugin, repoRoot = workspace_root_1.workspaceRoot, updatePackageScripts = false, verbose = false, pmc = (0, package_manager_1.getPackageManagerCommand)()) {
35
- const capabilities = await (0, plugins_1.getPluginCapabilities)(repoRoot, plugin, {});
36
- const generators = capabilities?.generators;
37
- if (!generators) {
38
- throw new Error(`No generators found in ${plugin}.`);
35
+ try {
36
+ (0, generator_utils_1.getGeneratorInformation)(plugin, 'init', workspace_root_1.workspaceRoot, {});
37
+ (0, child_process_1.execSync)(`${pmc.exec} nx g ${plugin}:init --keepExistingVersions ${updatePackageScripts ? '--updatePackageScripts' : ''} ${verbose ? '--verbose' : ''}`, {
38
+ stdio: [0, 1, 2],
39
+ cwd: repoRoot,
40
+ windowsHide: false,
41
+ });
39
42
  }
40
- const initGenerator = findInitGenerator(generators);
41
- if (!initGenerator) {
43
+ catch {
44
+ // init generator does not exist, so this function should noop
42
45
  output_1.output.log({
43
46
  title: `No "init" generator found in ${plugin}. Skipping initialization.`,
44
47
  });
45
48
  return;
46
49
  }
47
- (0, child_process_1.execSync)(`${pmc.exec} nx g ${plugin}:init --keepExistingVersions ${updatePackageScripts ? '--updatePackageScripts' : ''} ${verbose ? '--verbose' : ''}`, {
48
- stdio: [0, 1, 2],
49
- cwd: repoRoot,
50
- windowsHide: false,
51
- });
52
50
  }
53
51
  /**
54
52
  * Install plugins