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 <https://github.com/chatmail/core/pull/5575>,
created two new GitHub deployment environments and configured
trusted publishing for two packages (see the environment URLs) on https://www.npmjs.com/
This commit is contained in:
link2xt
2025-12-03 02:30:03 +00:00
committed by l
parent b41c309e21
commit 47c1e54219
2 changed files with 6 additions and 4 deletions

View File

@@ -10,6 +10,9 @@ jobs:
pack-module:
name: "Publish @deltachat/jsonrpc-client"
runs-on: ubuntu-latest
environment:
name: npm-jsonrpc-client
url: https://www.npmjs.com/package/@deltachat/jsonrpc-client
permissions:
id-token: write
contents: read
@@ -37,5 +40,3 @@ jobs:
- name: Publish
working-directory: deltachat-jsonrpc/typescript
run: npm publish --provenance deltachat-jsonrpc-client-* --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}