nx 20.1.0-canary.20241015-1badac8 → 20.1.0-canary.20241016-3634781
Sign up to get free protection for your applications and to get access to all the features.
- package/migrations.json +6 -0
- package/package.json +11 -11
- package/schemas/nx-schema.json +4 -0
- package/src/command-line/release/plan.js +1 -1
- package/src/config/nx-json.d.ts +1 -1
- package/src/hasher/file-hasher.d.ts +1 -0
- package/src/hasher/file-hasher.js +5 -0
- package/src/migrations/update-20-0-1/use-legacy-cache.d.ts +2 -0
- package/src/migrations/update-20-0-1/use-legacy-cache.js +20 -0
- package/src/native/nx.wasm32-wasi.wasm +0 -0
- package/src/utils/nx-cloud-utils.js +6 -0
package/migrations.json
CHANGED
@@ -57,6 +57,12 @@
|
|
57
57
|
"version": "20.0.0-beta.7",
|
58
58
|
"description": "Migration for v20.0.0-beta.7",
|
59
59
|
"implementation": "./src/migrations/update-20-0-0/move-use-daemon-process"
|
60
|
+
},
|
61
|
+
"use-legacy-cache": {
|
62
|
+
"version": "20.0.1",
|
63
|
+
"description": "Set `useLegacyCache` to true for migrating workspaces",
|
64
|
+
"implementation": "./src/migrations/update-20-0-1/use-legacy-cache",
|
65
|
+
"x-repair-skip": true
|
60
66
|
}
|
61
67
|
}
|
62
68
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "nx",
|
3
|
-
"version": "20.1.0-canary.
|
3
|
+
"version": "20.1.0-canary.20241016-3634781",
|
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": {
|
@@ -80,16 +80,16 @@
|
|
80
80
|
}
|
81
81
|
},
|
82
82
|
"optionalDependencies": {
|
83
|
-
"@nx/nx-darwin-x64": "20.1.0-canary.
|
84
|
-
"@nx/nx-darwin-arm64": "20.1.0-canary.
|
85
|
-
"@nx/nx-linux-x64-gnu": "20.1.0-canary.
|
86
|
-
"@nx/nx-linux-x64-musl": "20.1.0-canary.
|
87
|
-
"@nx/nx-win32-x64-msvc": "20.1.0-canary.
|
88
|
-
"@nx/nx-linux-arm64-gnu": "20.1.0-canary.
|
89
|
-
"@nx/nx-linux-arm64-musl": "20.1.0-canary.
|
90
|
-
"@nx/nx-linux-arm-gnueabihf": "20.1.0-canary.
|
91
|
-
"@nx/nx-win32-arm64-msvc": "20.1.0-canary.
|
92
|
-
"@nx/nx-freebsd-x64": "20.1.0-canary.
|
83
|
+
"@nx/nx-darwin-x64": "20.1.0-canary.20241016-3634781",
|
84
|
+
"@nx/nx-darwin-arm64": "20.1.0-canary.20241016-3634781",
|
85
|
+
"@nx/nx-linux-x64-gnu": "20.1.0-canary.20241016-3634781",
|
86
|
+
"@nx/nx-linux-x64-musl": "20.1.0-canary.20241016-3634781",
|
87
|
+
"@nx/nx-win32-x64-msvc": "20.1.0-canary.20241016-3634781",
|
88
|
+
"@nx/nx-linux-arm64-gnu": "20.1.0-canary.20241016-3634781",
|
89
|
+
"@nx/nx-linux-arm64-musl": "20.1.0-canary.20241016-3634781",
|
90
|
+
"@nx/nx-linux-arm-gnueabihf": "20.1.0-canary.20241016-3634781",
|
91
|
+
"@nx/nx-win32-arm64-msvc": "20.1.0-canary.20241016-3634781",
|
92
|
+
"@nx/nx-freebsd-x64": "20.1.0-canary.20241016-3634781"
|
93
93
|
},
|
94
94
|
"nx-migrations": {
|
95
95
|
"migrations": "./migrations.json",
|
package/schemas/nx-schema.json
CHANGED
@@ -89,6 +89,10 @@
|
|
89
89
|
"type": "string",
|
90
90
|
"description": "Specifies the encryption key used to encrypt artifacts data before sending it to nx cloud."
|
91
91
|
},
|
92
|
+
"neverConnectToCloud": {
|
93
|
+
"type": "boolean",
|
94
|
+
"description": "Set this to true to disable all connections to Nx Cloud."
|
95
|
+
},
|
92
96
|
"parallel": {
|
93
97
|
"type": "number",
|
94
98
|
"description": "Specifies how many tasks are ran in parallel by Nx for the default tasks runner."
|
@@ -50,7 +50,7 @@ function createAPI(overrideReleaseConfig) {
|
|
50
50
|
process.exit(1);
|
51
51
|
}
|
52
52
|
// If no release groups have version plans enabled, it doesn't make sense to use the plan command only to set yourself up for an error at release time
|
53
|
-
if (!releaseGroups.some((group) => group.versionPlans
|
53
|
+
if (!releaseGroups.some((group) => !!group.versionPlans)) {
|
54
54
|
if (releaseGroups.length === 1) {
|
55
55
|
output_1.output.warn({
|
56
56
|
title: `Version plans are not enabled in your release configuration`,
|
package/src/config/nx-json.d.ts
CHANGED
@@ -456,7 +456,7 @@ export interface NxJsonConfiguration<T = '*' | string[]> {
|
|
456
456
|
*/
|
457
457
|
useInferencePlugins?: boolean;
|
458
458
|
/**
|
459
|
-
* Set this to
|
459
|
+
* Set this to true to disable connection to Nx Cloud
|
460
460
|
*/
|
461
461
|
neverConnectToCloud?: boolean;
|
462
462
|
/**
|
@@ -2,6 +2,7 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.hashArray = hashArray;
|
4
4
|
exports.hashObject = hashObject;
|
5
|
+
exports.hashFile = hashFile;
|
5
6
|
function hashArray(content) {
|
6
7
|
// Import as needed. There is also an issue running unit tests in Nx repo if this is a top-level import.
|
7
8
|
const { hashArray } = require('../native');
|
@@ -16,3 +17,7 @@ function hashObject(obj) {
|
|
16
17
|
}
|
17
18
|
return hashArray(parts);
|
18
19
|
}
|
20
|
+
function hashFile(filePath) {
|
21
|
+
const { hashFile } = require('../native');
|
22
|
+
return hashFile(filePath);
|
23
|
+
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.default = update;
|
4
|
+
const format_changed_files_with_prettier_if_available_1 = require("../../generators/internal-utils/format-changed-files-with-prettier-if-available");
|
5
|
+
const nx_json_1 = require("../../generators/utils/nx-json");
|
6
|
+
async function update(tree) {
|
7
|
+
const nxJson = (0, nx_json_1.readNxJson)(tree);
|
8
|
+
if (!nxJson) {
|
9
|
+
return;
|
10
|
+
}
|
11
|
+
// If workspaces had `enableDbCache` we can just delete the property as the db cache is enabled by default in nx v20
|
12
|
+
if (nxJson.enableDbCache) {
|
13
|
+
delete nxJson.enableDbCache;
|
14
|
+
}
|
15
|
+
else {
|
16
|
+
nxJson.useLegacyCache = true;
|
17
|
+
}
|
18
|
+
(0, nx_json_1.updateNxJson)(tree, nxJson);
|
19
|
+
await (0, format_changed_files_with_prettier_if_available_1.formatChangedFilesWithPrettierIfAvailable)(tree);
|
20
|
+
}
|
Binary file
|
@@ -3,6 +3,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.isNxCloudUsed = isNxCloudUsed;
|
4
4
|
exports.getNxCloudUrl = getNxCloudUrl;
|
5
5
|
function isNxCloudUsed(nxJson) {
|
6
|
+
if (process.env.NX_NO_CLOUD === 'true') {
|
7
|
+
return false;
|
8
|
+
}
|
9
|
+
if (nxJson.neverConnectToCloud) {
|
10
|
+
return true;
|
11
|
+
}
|
6
12
|
return (!!process.env.NX_CLOUD_ACCESS_TOKEN ||
|
7
13
|
!!nxJson.nxCloudAccessToken ||
|
8
14
|
!!nxJson.nxCloudId ||
|