Skip to content

Commit ab8db55

Browse files
authored
[ci] Update GitHub Actions workflow for npm publishing
1 parent 4c60ae8 commit ab8db55

File tree

1 file changed

+13
-9
lines changed

1 file changed

+13
-9
lines changed
Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,24 @@
1-
# After new release is published on github, publish it to npmjs
2-
name: Publish on npmjs
3-
1+
name: Publish on npm
42
on:
53
release:
64
types: [published]
75

6+
permissions:
7+
id-token: write
8+
contents: read
9+
810
jobs:
911
publish:
1012
runs-on: ubuntu-latest
13+
environment: publish
14+
1115
steps:
12-
- uses: actions/checkout@v2
13-
- uses: actions/setup-node@v1
16+
- uses: actions/checkout@v4
17+
18+
- uses: actions/setup-node@v4
1419
with:
15-
node-version: 18
20+
node-version: 24
1621
registry-url: 'https://registry.npmjs.org'
22+
1723
- run: npm ci
18-
- run: npm publish --access public
19-
env:
20-
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
24+
- run: npm publish --provenance --access public

0 commit comments

Comments
 (0)