Skip to content

Commit 7916229

Browse files
committed
Update npm-publish workflow to use trusted publishing
1 parent c923754 commit 7916229

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

.github/workflows/npm-publish.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@ on:
33
release:
44
types:
55
- published
6+
7+
# Trusted publishing configuration. See https://docs.npmjs.com/trusted-publishers
8+
permissions:
9+
id-token: write
10+
contents: read
11+
612
jobs:
713
build-and-publish-package:
814
runs-on: ubuntu-latest
@@ -12,13 +18,11 @@ jobs:
1218
- name: Setup Nodejs
1319
uses: actions/setup-node@v4
1420
with:
15-
node-version: '16'
21+
node-version: '24'
1622
registry-url: 'https://registry.npmjs.org'
1723
- name: Install
1824
run: yarn install --immutable
1925
- name: Build
2026
run: yarn build
2127
- name: Publish package
2228
run: npm publish --access public
23-
env:
24-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)