@nx/gradle 19.5.0-canary.20240709-92e09d9 → 19.5.0-canary.20240710-2b7b523
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/gradle",
|
3
|
-
"version": "19.5.0-canary.
|
3
|
+
"version": "19.5.0-canary.20240710-2b7b523",
|
4
4
|
"private": false,
|
5
5
|
"description": "The Nx Plugin for Gradle allows Gradle tasks to be run through Nx",
|
6
6
|
"repository": {
|
@@ -34,7 +34,7 @@
|
|
34
34
|
"migrations": "./migrations.json"
|
35
35
|
},
|
36
36
|
"dependencies": {
|
37
|
-
"@nx/devkit": "19.5.0-canary.
|
37
|
+
"@nx/devkit": "19.5.0-canary.20240710-2b7b523"
|
38
38
|
},
|
39
39
|
"publishConfig": {
|
40
40
|
"access": "public"
|
@@ -14,10 +14,13 @@ jobs:
|
|
14
14
|
steps:
|
15
15
|
- checkout
|
16
16
|
|
17
|
-
#
|
18
|
-
#
|
17
|
+
# This enables task distribution via Nx Cloud
|
18
|
+
# Run this command as early as possible, before dependencies are installed
|
19
|
+
# Learn more at https://nx.dev/ci/reference/nx-cloud-cli#npx-nxcloud-startcirun
|
20
|
+
<% if (connectedToCloud) { %>- run: <%= packageManagerPrefix %> nx-cloud start-ci-run --distribute-on="5 linux-medium-jvm" --stop-agents-after="build"
|
21
|
+
<% } else { %># Connect your workspace by running "nx connect" and uncomment this
|
19
22
|
# - run: <%= packageManagerPrefix %> nx-cloud start-ci-run --distribute-on="5 linux-medium-jvm" --stop-agents-after="build"
|
20
|
-
|
23
|
+
<% } %>
|
21
24
|
- nx/set-shas:
|
22
25
|
main-branch-name: '<%= mainBranch %>'
|
23
26
|
|
package/src/generators/ci-workflow/files/github/.github/workflows/__workflowFileName__.yml.template
CHANGED
@@ -18,9 +18,13 @@ jobs:
|
|
18
18
|
with:
|
19
19
|
fetch-depth: 0
|
20
20
|
|
21
|
-
#
|
22
|
-
#
|
21
|
+
# This enables task distribution via Nx Cloud
|
22
|
+
# Run this command as early as possible, before dependencies are installed
|
23
|
+
# Learn more at https://nx.dev/ci/reference/nx-cloud-cli#npx-nxcloud-startcirun
|
24
|
+
<% if (connectedToCloud) { %>- run: <%= packageManagerPrefix %> nx-cloud start-ci-run --distribute-on="5 linux-medium-jvm" --stop-agents-after="build"
|
25
|
+
<% } else { %># Connect your workspace by running "nx connect" and uncomment this
|
23
26
|
# - run: <%= packageManagerPrefix %> nx-cloud start-ci-run --distribute-on="5 linux-medium-jvm" --stop-agents-after="build"
|
27
|
+
<% } %>
|
24
28
|
|
25
29
|
- name: Set up JDK 17 for x64
|
26
30
|
uses: actions/setup-java@v4
|
@@ -28,12 +28,13 @@ function getTemplateData(tree, options) {
|
|
28
28
|
const { exec: packageManagerPrefix } = (0, devkit_1.getPackageManagerCommand)(packageManager);
|
29
29
|
let nxCloudHost = 'nx.app';
|
30
30
|
try {
|
31
|
-
const nxCloudUrl = (0, nx_cloud_utils_1.getNxCloudUrl)((0, devkit_1.
|
31
|
+
const nxCloudUrl = (0, nx_cloud_utils_1.getNxCloudUrl)((0, devkit_1.readNxJson)(tree));
|
32
32
|
nxCloudHost = new URL(nxCloudUrl).host;
|
33
33
|
}
|
34
34
|
catch { }
|
35
35
|
const mainBranch = (0, default_base_1.deduceDefaultBase)();
|
36
36
|
const commands = options.commands ?? getCiCommands(options.ci, mainBranch);
|
37
|
+
const connectedToCloud = (0, nx_cloud_utils_1.isNxCloudUsed)((0, devkit_1.readNxJson)(tree));
|
37
38
|
return {
|
38
39
|
workflowName,
|
39
40
|
workflowFileName,
|
@@ -42,6 +43,7 @@ function getTemplateData(tree, options) {
|
|
42
43
|
commands,
|
43
44
|
mainBranch,
|
44
45
|
nxCloudHost,
|
46
|
+
connectedToCloud,
|
45
47
|
};
|
46
48
|
}
|
47
49
|
exports.default = ciWorkflowGenerator;
|