@nx/workspace 20.5.0-rc.3 → 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/workspace",
3
- "version": "20.5.0-rc.3",
3
+ "version": "20.5.0-rc.4",
4
4
  "private": false,
5
5
  "description": "The Workspace plugin contains executors and generators that are useful for any Nx workspace. It should be present in every Nx workspace and other plugins build on it.",
6
6
  "repository": {
@@ -38,12 +38,12 @@
38
38
  }
39
39
  },
40
40
  "dependencies": {
41
- "@nx/devkit": "20.5.0-rc.3",
41
+ "@nx/devkit": "20.5.0-rc.4",
42
42
  "chalk": "^4.1.0",
43
43
  "enquirer": "~2.3.6",
44
44
  "tslib": "^2.3.0",
45
45
  "yargs-parser": "21.1.1",
46
- "nx": "20.5.0-rc.3"
46
+ "nx": "20.5.0-rc.4"
47
47
  },
48
48
  "publishConfig": {
49
49
  "access": "public"
@@ -4,10 +4,9 @@ exports.npmPackageGenerator = npmPackageGenerator;
4
4
  const devkit_1 = require("@nx/devkit");
5
5
  const project_name_and_root_utils_1 = require("@nx/devkit/src/generators/project-name-and-root-utils");
6
6
  const path_1 = require("path");
7
- const get_import_path_1 = require("../../utilities/get-import-path");
8
7
  async function normalizeOptions(tree, options) {
9
- await (0, project_name_and_root_utils_1.ensureProjectName)(tree, options, 'library');
10
- const { projectName, projectRoot } = await (0, project_name_and_root_utils_1.determineProjectNameAndRootOptions)(tree, {
8
+ await (0, project_name_and_root_utils_1.ensureRootProjectName)(options, 'library');
9
+ const { projectName, projectRoot, importPath } = await (0, project_name_and_root_utils_1.determineProjectNameAndRootOptions)(tree, {
11
10
  name: options.name,
12
11
  projectType: 'library',
13
12
  directory: options.directory,
@@ -16,12 +15,13 @@ async function normalizeOptions(tree, options) {
16
15
  ...options,
17
16
  name: projectName,
18
17
  projectRoot,
18
+ importPath,
19
19
  };
20
20
  }
21
21
  function addFiles(projectRoot, tree, options) {
22
22
  const packageJsonPath = (0, path_1.join)(projectRoot, 'package.json');
23
23
  (0, devkit_1.writeJson)(tree, packageJsonPath, {
24
- name: (0, get_import_path_1.getImportPath)(tree, options.name),
24
+ name: options.importPath,
25
25
  version: '0.0.0',
26
26
  scripts: {
27
27
  test: 'node index.js',