@unisphere/nx 1.22.3 → 1.22.5
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/dist/migrations/1-22-0/check-nx-version.js +1 -1
- package/dist/migrations/1-22-0/replace-patches.d.ts.map +1 -1
- package/dist/migrations/1-22-0/replace-patches.js +9 -15
- package/dist/migrations/1-22-2/add-os-and-cpu.js +1 -1
- package/dist/migrations/1-22-2/templates/_publish-artifacts.template +28 -12
- package/dist/migrations/{1-22-3 → 1-22-4}/add-kaltura-tools-to-pre-install.d.ts.map +1 -1
- package/dist/migrations/1-22-4/summary.d.ts +2 -0
- package/dist/migrations/1-22-4/summary.d.ts.map +1 -0
- package/dist/migrations/{summaries/1-22-2-summary.js → 1-22-4/summary.js} +2 -2
- package/dist/migrations/summaries/1-22-4-summary.d.ts +2 -0
- package/dist/migrations/summaries/1-22-4-summary.d.ts.map +1 -0
- package/dist/migrations/summaries/1-22-4-summary.js +12 -0
- package/migrations.json +7 -12
- package/package.json +1 -1
- package/dist/migrations/1-22-0/templates/patches/@nx+rollup+22.1.3.patch +0 -27
- package/dist/migrations/summaries/1-22-2-summary.d.ts +0 -2
- package/dist/migrations/summaries/1-22-2-summary.d.ts.map +0 -1
- /package/dist/migrations/1-22-0/{templates/patches → patches}/@changesets+cli+2.29.7.patch +0 -0
- /package/dist/migrations/{1-22-3 → 1-22-4}/add-kaltura-tools-to-pre-install.d.ts +0 -0
- /package/dist/migrations/{1-22-3 → 1-22-4}/add-kaltura-tools-to-pre-install.js +0 -0
|
@@ -12,7 +12,7 @@ function checkNxVersion(tree) {
|
|
|
12
12
|
}
|
|
13
13
|
const majorVersion = parseInt(nxVersion.match(/\d+/)?.[0] ?? '0');
|
|
14
14
|
if (majorVersion < 22) {
|
|
15
|
-
const errorMessage = `❌ This migration requires Nx 22 or higher. read https://unisphere.kaltura.com/docs/create/changelog/1-22-
|
|
15
|
+
const errorMessage = `❌ This migration requires Nx 22 or higher. read https://unisphere.kaltura.com/docs/create/changelog/1-22-5-changelog`;
|
|
16
16
|
devkit_1.logger.error(errorMessage);
|
|
17
17
|
throw new Error(errorMessage);
|
|
18
18
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"replace-patches.d.ts","sourceRoot":"","sources":["../../../src/migrations/1-22-0/replace-patches.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,
|
|
1
|
+
{"version":3,"file":"replace-patches.d.ts","sourceRoot":"","sources":["../../../src/migrations/1-22-0/replace-patches.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAyB,MAAM,YAAY,CAAC;AAKzD,wBAA8B,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAiC9D"}
|
|
@@ -3,35 +3,29 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.default = update;
|
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
|
5
5
|
const path_1 = require("path");
|
|
6
|
+
const removePatchList = ['@changesets+cli'];
|
|
6
7
|
async function update(tree) {
|
|
7
8
|
devkit_1.logger.info('🔄 Creating patches');
|
|
8
9
|
try {
|
|
9
|
-
// Check @nx/rollup version
|
|
10
|
-
const pkg = (0, devkit_1.readJson)(tree, 'package.json');
|
|
11
|
-
const nxVersion = pkg.devDependencies?.['@nx/rollup'] || pkg.dependencies?.['@nx/rollup'];
|
|
12
|
-
if (nxVersion !== '22.1.3') {
|
|
13
|
-
devkit_1.logger.error('❌ @nx/rollup version must be exactly 22.1.3');
|
|
14
|
-
throw new Error('@nx/rollup version must be exactly 22.1.3. did you migrate nx to other version?');
|
|
15
|
-
}
|
|
16
10
|
// Create patches
|
|
17
11
|
const patchesPath = 'patches';
|
|
18
|
-
const patchesTemplatePath = (0, path_1.join)(__dirname, '
|
|
12
|
+
const patchesTemplatePath = (0, path_1.join)(__dirname, 'patches');
|
|
19
13
|
// Delete existing patches folder content if it exists
|
|
20
14
|
if (tree.exists(patchesPath)) {
|
|
21
15
|
const existingFiles = tree.children(patchesPath);
|
|
22
16
|
for (const file of existingFiles) {
|
|
23
|
-
|
|
24
|
-
|
|
17
|
+
if (removePatchList.some(patch => file.includes(patch))) {
|
|
18
|
+
devkit_1.logger.info(`🗑️ Removing existing patch: ${file}`);
|
|
19
|
+
tree.delete((0, path_1.join)(patchesPath, file));
|
|
20
|
+
}
|
|
21
|
+
else {
|
|
22
|
+
devkit_1.logger.info(`✅ Patch: ${file} is up to date`);
|
|
23
|
+
}
|
|
25
24
|
}
|
|
26
25
|
devkit_1.logger.info(`🧹 Cleaned up existing patches folder`);
|
|
27
26
|
}
|
|
28
27
|
// Copy all patch files using generateFiles
|
|
29
28
|
(0, devkit_1.generateFiles)(tree, patchesTemplatePath, `./${patchesPath}`, {});
|
|
30
|
-
// Log created patches
|
|
31
|
-
const createdPatches = tree.children(patchesPath);
|
|
32
|
-
for (const patchFile of createdPatches) {
|
|
33
|
-
devkit_1.logger.info(`✅ Created patch: ${patchFile}`);
|
|
34
|
-
}
|
|
35
29
|
// Always log that patches were created
|
|
36
30
|
devkit_1.logger.info(`✅ All patches created successfully`);
|
|
37
31
|
}
|
|
@@ -12,7 +12,7 @@ jobs:
|
|
|
12
12
|
has_applications: ${{ steps.check.outputs.has_applications }}
|
|
13
13
|
steps:
|
|
14
14
|
- name: Checkout Repo
|
|
15
|
-
uses: actions/checkout@
|
|
15
|
+
uses: actions/checkout@v4
|
|
16
16
|
with:
|
|
17
17
|
ref: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}
|
|
18
18
|
fetch-tags: true
|
|
@@ -58,7 +58,7 @@ jobs:
|
|
|
58
58
|
commit_sha: ${{ steps.capture_commit_sha.outputs.commit_sha }}
|
|
59
59
|
steps:
|
|
60
60
|
- name: Checkout Repo
|
|
61
|
-
uses: actions/checkout@
|
|
61
|
+
uses: actions/checkout@v4
|
|
62
62
|
with:
|
|
63
63
|
ref: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}
|
|
64
64
|
fetch-tags: true
|
|
@@ -107,14 +107,14 @@ jobs:
|
|
|
107
107
|
runs-on: codebuild-ovp-unisphere-runner-${{ github.run_id }}-${{ github.attempt }}
|
|
108
108
|
steps:
|
|
109
109
|
- name: Checkout Repo
|
|
110
|
-
uses: actions/checkout@
|
|
110
|
+
uses: actions/checkout@v4
|
|
111
111
|
with:
|
|
112
112
|
ref: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}
|
|
113
113
|
fetch-tags: true
|
|
114
114
|
- name: Setup Node.js
|
|
115
115
|
uses: actions/setup-node@v4
|
|
116
116
|
with:
|
|
117
|
-
node-version:
|
|
117
|
+
node-version-file: '.nvmrc'
|
|
118
118
|
|
|
119
119
|
- name: Setup JFrog
|
|
120
120
|
uses: jfrog/setup-jfrog-cli@v4
|
|
@@ -140,7 +140,7 @@ jobs:
|
|
|
140
140
|
# Debug token existence (safely)
|
|
141
141
|
echo "::debug::Token exists: $([ ! -z "$NPM_TOKEN" ] && echo 'true' || echo 'false')"
|
|
142
142
|
- name: Deploy to registry
|
|
143
|
-
run: npx unisphere package publish --verbose --githubToken ${{ secrets.GITHUB_TOKEN }} --
|
|
143
|
+
run: npx unisphere package publish --verbose --githubToken ${{ secrets.GITHUB_TOKEN }} --npmToken ${{ env.NPM_TOKEN }} --branch "${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}"
|
|
144
144
|
|
|
145
145
|
deploy-runtimes:
|
|
146
146
|
if: needs.prepare-runtimes.outputs.hasArtifacts == 'true'
|
|
@@ -162,14 +162,14 @@ jobs:
|
|
|
162
162
|
- name: Check available disk space
|
|
163
163
|
run: df -h
|
|
164
164
|
- name: Checkout Repo at specific commit
|
|
165
|
-
uses: actions/checkout@
|
|
165
|
+
uses: actions/checkout@v4
|
|
166
166
|
with:
|
|
167
167
|
ref: ${{ needs.prepare-runtimes.outputs.commit_sha }}
|
|
168
168
|
fetch-tags: true
|
|
169
169
|
- name: Setup Node.js
|
|
170
170
|
uses: actions/setup-node@v4
|
|
171
171
|
with:
|
|
172
|
-
node-version:
|
|
172
|
+
node-version-file: '.nvmrc'
|
|
173
173
|
|
|
174
174
|
- name: Setup JFrog
|
|
175
175
|
uses: jfrog/setup-jfrog-cli@v4
|
|
@@ -212,7 +212,7 @@ jobs:
|
|
|
212
212
|
commit_sha: ${{ steps.capture_commit_sha.outputs.commit_sha }}
|
|
213
213
|
steps:
|
|
214
214
|
- name: Checkout Repo
|
|
215
|
-
uses: actions/checkout@
|
|
215
|
+
uses: actions/checkout@v4
|
|
216
216
|
with:
|
|
217
217
|
ref: ${{ github.event_name == 'pull_request' && github.head_ref || github.ref }}
|
|
218
218
|
fetch-tags: true
|
|
@@ -224,10 +224,18 @@ jobs:
|
|
|
224
224
|
run: git reset --hard HEAD
|
|
225
225
|
- name: Clean npm cache
|
|
226
226
|
run: npm cache clean --force
|
|
227
|
+
- name: Setup JFrog
|
|
228
|
+
uses: jfrog/setup-jfrog-cli@v4
|
|
229
|
+
id: setup-jfrog
|
|
230
|
+
env:
|
|
231
|
+
JF_URL: https://kalturaa.jfrog.io
|
|
232
|
+
with:
|
|
233
|
+
oidc-provider-name: ovp-github-oidc
|
|
227
234
|
- name: Install dependencies
|
|
228
|
-
run: npm ci --ignore-scripts
|
|
235
|
+
run: npm ci --ignore-scripts
|
|
229
236
|
env:
|
|
230
237
|
GIT_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
238
|
+
KALTURA_JFROG_TOKEN: ${{ steps.setup-jfrog.outputs.oidc-token }}
|
|
231
239
|
- name: Prepare Unisphere Applications
|
|
232
240
|
id: prepare-applications
|
|
233
241
|
run: npx unisphere application publish prepare --verbose
|
|
@@ -263,18 +271,26 @@ jobs:
|
|
|
263
271
|
fail-fast: false
|
|
264
272
|
steps:
|
|
265
273
|
- name: Checkout Repo at specific commit
|
|
266
|
-
uses: actions/checkout@
|
|
274
|
+
uses: actions/checkout@v4
|
|
267
275
|
with:
|
|
268
276
|
ref: ${{ needs.prepare-applications.outputs.commit_sha }}
|
|
269
277
|
fetch-tags: true
|
|
270
278
|
- name: Setup Node.js
|
|
271
279
|
uses: actions/setup-node@v4
|
|
272
280
|
with:
|
|
273
|
-
node-version:
|
|
281
|
+
node-version-file: '.nvmrc'
|
|
282
|
+
- name: Setup JFrog
|
|
283
|
+
uses: jfrog/setup-jfrog-cli@v4
|
|
284
|
+
id: setup-jfrog
|
|
285
|
+
env:
|
|
286
|
+
JF_URL: https://kalturaa.jfrog.io
|
|
287
|
+
with:
|
|
288
|
+
oidc-provider-name: ovp-github-oidc
|
|
274
289
|
- name: Install dependencies
|
|
275
|
-
run: npm ci --ignore-scripts
|
|
290
|
+
run: npm ci --ignore-scripts
|
|
276
291
|
env:
|
|
277
292
|
GIT_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
293
|
+
KALTURA_JFROG_TOKEN: ${{ steps.setup-jfrog.outputs.oidc-token }}
|
|
278
294
|
- name: Download artifacts folder
|
|
279
295
|
uses: actions/download-artifact@v4
|
|
280
296
|
with:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"add-kaltura-tools-to-pre-install.d.ts","sourceRoot":"","sources":["../../../src/migrations/1-22-
|
|
1
|
+
{"version":3,"file":"add-kaltura-tools-to-pre-install.d.ts","sourceRoot":"","sources":["../../../src/migrations/1-22-4/add-kaltura-tools-to-pre-install.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAsB,MAAM,YAAY,CAAC;AAEtD,wBAA8B,MAAM,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAoB9D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"summary.d.ts","sourceRoot":"","sources":["../../../src/migrations/1-22-4/summary.ts"],"names":[],"mappings":"AAEA,0CAOC"}
|
|
@@ -4,9 +4,9 @@ exports.default = default_1;
|
|
|
4
4
|
const devkit_1 = require("@nx/devkit");
|
|
5
5
|
async function default_1() {
|
|
6
6
|
devkit_1.logger.info('');
|
|
7
|
-
devkit_1.logger.info('🎉 Migration to @unisphere/nx 1.22.
|
|
7
|
+
devkit_1.logger.info('🎉 Migration to @unisphere/nx 1.22.4 finished successfully!');
|
|
8
8
|
devkit_1.logger.info('');
|
|
9
9
|
devkit_1.logger.info('📋 Full details:');
|
|
10
|
-
devkit_1.logger.info('https://unisphere.kaltura.com/docs/create/changelog/1-22-
|
|
10
|
+
devkit_1.logger.info('https://unisphere.kaltura.com/docs/create/changelog/1-22-5-changelog');
|
|
11
11
|
devkit_1.logger.info('');
|
|
12
12
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"1-22-4-summary.d.ts","sourceRoot":"","sources":["../../../src/migrations/summaries/1-22-4-summary.ts"],"names":[],"mappings":"AAEA,0CAOC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = default_1;
|
|
4
|
+
const devkit_1 = require("@nx/devkit");
|
|
5
|
+
async function default_1() {
|
|
6
|
+
devkit_1.logger.info('');
|
|
7
|
+
devkit_1.logger.info('🎉 Migration to @unisphere/nx 1.22.4 finished successfully!');
|
|
8
|
+
devkit_1.logger.info('');
|
|
9
|
+
devkit_1.logger.info('📋 Full details:');
|
|
10
|
+
devkit_1.logger.info('https://unisphere.kaltura.com/docs/create/changelog/1-22-5-changelog');
|
|
11
|
+
devkit_1.logger.info('');
|
|
12
|
+
}
|
package/migrations.json
CHANGED
|
@@ -53,15 +53,15 @@
|
|
|
53
53
|
"postUpdateMessage": "✅ GitHub workflow updated with some changes."
|
|
54
54
|
}
|
|
55
55
|
},
|
|
56
|
-
"1-22-
|
|
57
|
-
"version": "1.22.
|
|
56
|
+
"1-22-4-add-kaltura-tools-to-pre-install": {
|
|
57
|
+
"version": "1.22.4",
|
|
58
58
|
"description": "Adds kaltura-tools to preinstall script",
|
|
59
|
-
"factory": "./dist/migrations/1-22-
|
|
59
|
+
"factory": "./dist/migrations/1-22-4/add-kaltura-tools-to-pre-install.js"
|
|
60
60
|
},
|
|
61
|
-
"000-1-22-
|
|
62
|
-
"version": "1.22.
|
|
63
|
-
"description": "Migration completion summary for 1.22.
|
|
64
|
-
"factory": "./dist/migrations/summaries/1-22-
|
|
61
|
+
"000-1-22-4-summary": {
|
|
62
|
+
"version": "1.22.4",
|
|
63
|
+
"description": "Migration completion summary for 1.22.4",
|
|
64
|
+
"factory": "./dist/migrations/summaries/1-22-4-summary.js"
|
|
65
65
|
}
|
|
66
66
|
},
|
|
67
67
|
"packageJsonUpdates": {
|
|
@@ -90,11 +90,6 @@
|
|
|
90
90
|
"version": "1.72.0",
|
|
91
91
|
"alwaysAddToPackageJson": false
|
|
92
92
|
},
|
|
93
|
-
"@nx/nx-linux-x64-gnu": {
|
|
94
|
-
"version": "^22.0.1",
|
|
95
|
-
"addToPackageJson": "optionalDependencies",
|
|
96
|
-
"alwaysAddToPackageJson": false
|
|
97
|
-
},
|
|
98
93
|
"@changesets/cli": {
|
|
99
94
|
"version": "2.29.7",
|
|
100
95
|
"alwaysAddToPackageJson": true
|
package/package.json
CHANGED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
diff --git a/node_modules/@nx/rollup/src/plugins/with-nx/with-nx.js b/node_modules/@nx/rollup/src/plugins/with-nx/with-nx.js
|
|
2
|
-
index 1135bba..4762053 100644
|
|
3
|
-
--- a/node_modules/@nx/rollup/src/plugins/with-nx/with-nx.js
|
|
4
|
-
+++ b/node_modules/@nx/rollup/src/plugins/with-nx/with-nx.js
|
|
5
|
-
@@ -149,7 +149,13 @@ dependencies) {
|
|
6
|
-
else {
|
|
7
|
-
options.generatePackageJson ??= true;
|
|
8
|
-
}
|
|
9
|
-
- const compilerOptions = createTsCompilerOptions(projectRoot, tsConfig, options, dependencies);
|
|
10
|
-
+ let compilerOptionsInterceptor = ((config) => config);
|
|
11
|
-
+ if (rollupConfig.unisphere?.interceptors?.compilerOptions) {
|
|
12
|
-
+ console.log(`[unisphere.nx.rollup] using monkey patched interceptor for TS compiler options`);
|
|
13
|
-
+ compilerOptionsInterceptor = rollupConfig.unisphere?.interceptors?.compilerOptions;
|
|
14
|
-
+ }
|
|
15
|
-
+
|
|
16
|
-
+ const compilerOptions = compilerOptionsInterceptor(createTsCompilerOptions(projectRoot, tsConfig, options, dependencies));
|
|
17
|
-
compilerOptions.outDir = Array.isArray(finalConfig.output)
|
|
18
|
-
? finalConfig.output[0].dir
|
|
19
|
-
: finalConfig.output.dir;
|
|
20
|
-
@@ -170,6 +176,7 @@ dependencies) {
|
|
21
|
-
return require('rollup-plugin-typescript2')({
|
|
22
|
-
check: !options.skipTypeCheck,
|
|
23
|
-
tsconfig: tsConfigPath,
|
|
24
|
-
+ exclude: ['**/*.stories.ts', '**/*.stories.tsx'],
|
|
25
|
-
tsconfigOverride: {
|
|
26
|
-
compilerOptions,
|
|
27
|
-
},
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"1-22-2-summary.d.ts","sourceRoot":"","sources":["../../../src/migrations/summaries/1-22-2-summary.ts"],"names":[],"mappings":"AAEA,0CAOC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|