Skip to content

Commit 47c1e54

Browse files
committed
ci: use "trusted publishing" for NPM packages
See the documentation at <https://docs.npmjs.com/trusted-publishers>. I have removed the token that was used since <#5575>, created two new GitHub deployment environments and configured trusted publishing for two packages (see the environment URLs) on https://www.npmjs.com/
1 parent b41c309 commit 47c1e54

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

.github/workflows/deltachat-rpc-server.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,9 @@ jobs:
388388
name: Build & Publish npm prebuilds and deltachat-rpc-server
389389
needs: ["build_linux", "build_windows", "build_macos"]
390390
runs-on: "ubuntu-latest"
391+
environment:
392+
name: npm-stdio-rpc-server
393+
url: https://www.npmjs.com/package/@deltachat/stdio-rpc-server
391394
permissions:
392395
id-token: write
393396

@@ -521,5 +524,3 @@ jobs:
521524
run: |
522525
ls -lah platform_package
523526
for platform in *.tgz; do npm publish --provenance "$platform" --access public; done
524-
env:
525-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

.github/workflows/jsonrpc-client-npm-package.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ jobs:
1010
pack-module:
1111
name: "Publish @deltachat/jsonrpc-client"
1212
runs-on: ubuntu-latest
13+
environment:
14+
name: npm-jsonrpc-client
15+
url: https://www.npmjs.com/package/@deltachat/jsonrpc-client
1316
permissions:
1417
id-token: write
1518
contents: read
@@ -37,5 +40,3 @@ jobs:
3740
- name: Publish
3841
working-directory: deltachat-jsonrpc/typescript
3942
run: npm publish --provenance deltachat-jsonrpc-client-* --access public
40-
env:
41-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)