@nx/js 17.3.1 → 17.3.2

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/js",
3
- "version": "17.3.1",
3
+ "version": "17.3.2",
4
4
  "private": false,
5
5
  "description": "The JS plugin for Nx contains executors and generators that provide the best experience for developing JavaScript and TypeScript projects. ",
6
6
  "repository": {
@@ -54,12 +54,12 @@
54
54
  "js-tokens": "^4.0.0",
55
55
  "minimatch": "9.0.3",
56
56
  "ora": "5.3.0",
57
- "semver": "7.5.3",
57
+ "semver": "^7.5.3",
58
58
  "source-map-support": "0.5.19",
59
59
  "tslib": "^2.3.0",
60
- "@nx/devkit": "17.3.1",
61
- "@nx/workspace": "17.3.1",
62
- "@nrwl/js": "17.3.1"
60
+ "@nx/devkit": "17.3.2",
61
+ "@nx/workspace": "17.3.2",
62
+ "@nrwl/js": "17.3.2"
63
63
  },
64
64
  "peerDependencies": {
65
65
  "verdaccio": "^5.0.4"
@@ -14,23 +14,30 @@ async function updateLockFile(cwd, { dryRun, verbose, generatorOptions, }) {
14
14
  }
15
15
  return [];
16
16
  }
17
+ const packageManager = (0, devkit_1.detectPackageManager)(cwd);
18
+ if (packageManager === 'yarn' &&
19
+ !(0, semver_1.gte)((0, devkit_1.getPackageManagerVersion)(packageManager), '2.0.0')) {
20
+ // yarn classic does not store workspace data in the lock file, so we don't need to update it
21
+ if (verbose) {
22
+ console.log('\nSkipped lock file update because it is not necessary for Yarn Classic.');
23
+ }
24
+ return [];
25
+ }
17
26
  const isDaemonEnabled = client_1.daemonClient.enabled();
18
27
  if (isDaemonEnabled) {
19
28
  // temporarily stop the daemon, as it will error if the lock file is updated
20
29
  await client_1.daemonClient.stop();
21
30
  }
22
- const packageManager = (0, devkit_1.detectPackageManager)(cwd);
23
31
  const packageManagerCommands = (0, devkit_1.getPackageManagerCommand)(packageManager);
24
32
  let installArgs = generatorOptions?.installArgs || '';
25
33
  devkit_1.output.logSingleLine(`Updating ${packageManager} lock file`);
26
34
  let env = {};
27
35
  if (generatorOptions?.installIgnoreScripts) {
28
- if (packageManager === 'yarn' &&
29
- (0, semver_1.gte)((0, devkit_1.getPackageManagerVersion)(packageManager), '2.0.0')) {
36
+ if (packageManager === 'yarn') {
30
37
  env = { YARN_ENABLE_SCRIPTS: 'false' };
31
38
  }
32
39
  else {
33
- // npm, pnpm, and yarn classic all use the same --ignore-scripts option
40
+ // npm and pnpm use the same --ignore-scripts option
34
41
  installArgs = `${installArgs} --ignore-scripts`.trim();
35
42
  }
36
43
  }