Skip to content

Commit 346cd0e

Browse files
committed
ci: fix npm authentication by using setup-node's NODE_AUTH_TOKEN
1 parent aaf73a5 commit 346cd0e

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

.github/workflows/nodejs-publish.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,12 @@ jobs:
3838
run: pnpm -w build
3939

4040
- name: Verify npm authentication
41-
run: |
42-
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
43-
npm whoami
41+
run: npm whoami
4442
env:
45-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
43+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
4644

4745
- name: Publish with Changesets
4846
run: pnpm release
4947
env:
5048
NPM_CONFIG_PROVENANCE: true
5149
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
52-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)