Skip to content

Commit d1142c4

Browse files
committed
ci: use trusted publisher for npm publish
No longer needs the `NPM_TOKEN` secret. But the "Publish" environment is kept for deployment protection.
1 parent 828744b commit d1142c4

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

.github/workflows/publish.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ jobs:
1919
with:
2020
node-version: 'lts/*'
2121
registry-url: 'https://registry.npmjs.org'
22+
# Ensure npm 11.5.1 or later is installed
23+
- name: Update npm
24+
run: npm install -g npm@latest
2225
- run: npm publish
23-
env:
24-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)