Skip to content

Commit be599a8

Browse files
authored
Update release workflow to use npm trusted publishing (#781)
1 parent 1fce3c3 commit be599a8

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

.github/workflows/release.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,22 +52,23 @@ jobs:
5252
if: startsWith(github.ref, 'refs/tags/v')
5353
runs-on: ubuntu-latest
5454
needs: build
55+
permissions:
56+
id-token: write # Required for OIDC
57+
contents: read
5558
steps:
5659
- name: set env
5760
run: echo "RELEASE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
5861
- uses: actions/checkout@v3
5962
- uses: actions/download-artifact@v4.1.7
6063
- run: ls */* | cat
61-
- uses: actions/setup-node@v3
64+
- uses: actions/setup-node@v4
6265
with:
63-
node-version: '16.x'
66+
node-version: '24.x'
6467
registry-url: 'https://registry.npmjs.org'
6568
- run: npm install
6669
- name: npm publish
6770
# skip npm publishing if running in a fork
6871
if: github.repository == 'amazon-ion/ion-js'
69-
env:
70-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
7172
run: npm publish
7273
update-docs:
7374
if: startsWith(github.ref, 'refs/tags/v')

0 commit comments

Comments
 (0)