Skip to content

Commit a8a55a6

Browse files
committed
chore: switch release workflow to npm trusted publishing
1 parent 44f5fb5 commit a8a55a6

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

.github/workflows/release.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ on:
77

88
concurrency: ${{ github.workflow }}-${{ github.ref }}
99

10+
permissions:
11+
contents: write
12+
pull-requests: write
13+
id-token: write
14+
1015
jobs:
1116
release:
1217
name: Release
@@ -43,6 +48,10 @@ jobs:
4348
uses: actions/setup-node@v4
4449
with:
4550
node-version: 20.x
51+
registry-url: 'https://registry.npmjs.org'
52+
53+
- name: Upgrade npm for trusted publishing (OIDC)
54+
run: npm i -g npm@11.5.1
4655

4756
- name: Install and prepare
4857
run: pnpm install --frozen-lockfile --strict-peer-dependencies
@@ -54,4 +63,3 @@ jobs:
5463
publish: pnpm run release
5564
env:
5665
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
57-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)