Skip to content

Commit 23a912b

Browse files
authored
fix(ci): @tauri-apps/cli publish workflow (#10659)
* fix(ci): pnpm install * fix setup-node * node16 setup fails somehow * remove unnecessary install deps step * run nodejs directly * fix permissions * fix metadata
1 parent dcc62e6 commit 23a912b

File tree

12 files changed

+132
-30
lines changed

12 files changed

+132
-30
lines changed

.github/workflows/publish-cli-js.yml

Lines changed: 11 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ jobs:
9797
uses: actions/setup-node@v4
9898
if: ${{ !matrix.settings.docker }}
9999
with:
100-
node-version: 16
101-
check-latest: true
100+
node-version: 18
102101
cache: 'pnpm'
103102
architecture: ${{ matrix.settings.architecture }}
104103
- name: Install Rust
@@ -116,7 +115,7 @@ jobs:
116115
if: ${{ matrix.settings.setup }}
117116
shell: bash
118117
- name: Install dependencies
119-
run: pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
118+
run: pnpm i --frozen-lockfile --ignore-scripts
120119

121120
- name: Build in docker
122121
uses: addnab/docker-run-action@v3
@@ -175,7 +174,7 @@ jobs:
175174
# env
176175
# freebsd-version
177176
# cd ./tooling/cli/node/
178-
# pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
177+
# pnpm i --frozen-lockfile --ignore-scripts
179178
# pnpm build:release
180179
# strip -x *.node
181180
# rm -rf node_modules
@@ -199,7 +198,6 @@ jobs:
199198
- host: windows-latest
200199
target: x86_64-pc-windows-msvc
201200
node:
202-
- '16'
203201
- '18'
204202
- '20'
205203
runs-on: ${{ matrix.settings.host }}
@@ -210,10 +208,9 @@ jobs:
210208
uses: actions/setup-node@v4
211209
with:
212210
node-version: ${{ matrix.node }}
213-
check-latest: true
214211
cache: 'pnpm'
215212
- name: Install dependencies
216-
run: pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
213+
run: pnpm i --frozen-lockfile --ignore-scripts
217214
- name: Download artifacts
218215
uses: actions/download-artifact@v3
219216
with:
@@ -232,7 +229,6 @@ jobs:
232229
fail-fast: false
233230
matrix:
234231
node:
235-
- '16'
236232
- '18'
237233
- '20'
238234
runs-on: ubuntu-latest
@@ -243,10 +239,9 @@ jobs:
243239
uses: actions/setup-node@v4
244240
with:
245241
node-version: ${{ matrix.node }}
246-
check-latest: true
247242
cache: 'pnpm'
248243
- name: Install dependencies
249-
run: pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
244+
run: pnpm i --frozen-lockfile --ignore-scripts
250245
- name: Download artifacts
251246
uses: actions/download-artifact@v3
252247
with:
@@ -269,7 +264,6 @@ jobs:
269264
fail-fast: false
270265
matrix:
271266
node:
272-
- '16'
273267
- '18'
274268
- '20'
275269
runs-on: ubuntu-latest
@@ -282,10 +276,9 @@ jobs:
282276
uses: actions/setup-node@v4
283277
with:
284278
node-version: ${{ matrix.node }}
285-
check-latest: true
286279
cache: 'pnpm'
287280
- name: Install dependencies
288-
run: pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
281+
run: pnpm i --frozen-lockfile --ignore-scripts
289282
- name: Download artifacts
290283
uses: actions/download-artifact@v3
291284
with:
@@ -312,7 +305,6 @@ jobs:
312305
fail-fast: false
313306
matrix:
314307
node:
315-
- '16'
316308
- '18'
317309
- '20'
318310
image:
@@ -326,8 +318,6 @@ jobs:
326318
- name: List packages
327319
run: ls -R .
328320
shell: bash
329-
- name: Install dependencies
330-
run: pnpm i --frozen-lockfile --ignore-scripts --frozen-lockfile --registry https://registry.npmjs.org --network-timeout 300000
331321
- name: Download aarch64-gnu artifacts
332322
uses: actions/download-artifact@v3
333323
with:
@@ -356,7 +346,7 @@ jobs:
356346
fnm install ${{ matrix.node }}
357347
fnm use ${{ matrix.node }}
358348
cd tooling/cli/node
359-
pnpm tauri --help
349+
node tauri.js --help
360350
ls -la
361351
publish:
362352
name: Publish
@@ -367,17 +357,19 @@ jobs:
367357
- test-linux-x64-gnu-binding
368358
- test-linux-x64-musl-binding
369359
#- test-linux-arm-bindings
360+
permissions:
361+
contents: write # update release
362+
id-token: write # npm provenance
370363
steps:
371364
- uses: actions/checkout@v4
372365
- run: corepack enable
373366
- name: Setup node
374367
uses: actions/setup-node@v4
375368
with:
376369
node-version: 20
377-
check-latest: true
378370
cache: 'pnpm'
379371
- name: Install dependencies
380-
run: pnpm i --frozen-lockfile --ignore-scripts --registry https://registry.npmjs.org --network-timeout 300000
372+
run: pnpm i --frozen-lockfile --ignore-scripts
381373
- name: Download all artifacts
382374
uses: actions/download-artifact@v3
383375
with:

tooling/cli/node/npm/darwin-arm64/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-darwin-arm64",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -14,7 +26,6 @@
1426
"files": [
1527
"cli.darwin-arm64.node"
1628
],
17-
"license": "MIT",
1829
"engines": {
1930
"node": ">= 10"
2031
}

tooling/cli/node/npm/darwin-x64/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-darwin-x64",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -14,7 +26,6 @@
1426
"files": [
1527
"cli.darwin-x64.node"
1628
],
17-
"license": "MIT",
1829
"engines": {
1930
"node": ">= 10"
2031
}

tooling/cli/node/npm/linux-arm-gnueabihf/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-linux-arm-gnueabihf",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -14,7 +26,6 @@
1426
"files": [
1527
"cli.linux-arm-gnueabihf.node"
1628
],
17-
"license": "MIT",
1829
"engines": {
1930
"node": ">= 10"
2031
}

tooling/cli/node/npm/linux-arm64-gnu/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-linux-arm64-gnu",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -17,7 +29,6 @@
1729
"files": [
1830
"cli.linux-arm64-gnu.node"
1931
],
20-
"license": "MIT",
2132
"engines": {
2233
"node": ">= 10"
2334
}

tooling/cli/node/npm/linux-arm64-musl/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-linux-arm64-musl",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -17,7 +29,6 @@
1729
"files": [
1830
"cli.linux-arm64-musl.node"
1931
],
20-
"license": "MIT",
2132
"engines": {
2233
"node": ">= 10"
2334
}

tooling/cli/node/npm/linux-x64-gnu/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-linux-x64-gnu",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -17,7 +29,6 @@
1729
"files": [
1830
"cli.linux-x64-gnu.node"
1931
],
20-
"license": "MIT",
2132
"engines": {
2233
"node": ">= 10"
2334
}

tooling/cli/node/npm/linux-x64-musl/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-linux-x64-musl",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -17,7 +29,6 @@
1729
"files": [
1830
"cli.linux-x64-musl.node"
1931
],
20-
"license": "MIT",
2132
"engines": {
2233
"node": ">= 10"
2334
}

tooling/cli/node/npm/win32-arm64-msvc/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-win32-arm64-msvc",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -14,7 +26,6 @@
1426
"files": [
1527
"cli.win32-arm64-msvc.node"
1628
],
17-
"license": "MIT",
1829
"engines": {
1930
"node": ">= 10"
2031
}

tooling/cli/node/npm/win32-ia32-msvc/package.json

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
{
22
"name": "@tauri-apps/cli-win32-ia32-msvc",
33
"version": "0.0.0",
4+
"repository": {
5+
"type": "git",
6+
"url": "git+https://github.com/tauri-apps/tauri.git"
7+
},
8+
"homepage": "https://github.com/tauri-apps/tauri#readme",
9+
"bugs": {
10+
"url": "https://github.com/tauri-apps/tauri/issues"
11+
},
12+
"contributors": [
13+
"Tauri Programme within The Commons Conservancy"
14+
],
15+
"license": "Apache-2.0 OR MIT",
416
"publishConfig": {
517
"access": "public"
618
},
@@ -14,7 +26,6 @@
1426
"files": [
1527
"cli.win32-ia32-msvc.node"
1628
],
17-
"license": "MIT",
1829
"engines": {
1930
"node": ">= 10"
2031
}

0 commit comments

Comments
 (0)