Skip to content

Commit 79d7560

Browse files
risantosdiogotorres97
authored andcommitted
Update release workflow to use trusted OIDC publishing
1 parent 107697d commit 79d7560

2 files changed

Lines changed: 8 additions & 6 deletions

File tree

.github/workflows/release.yaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ jobs:
2020
group: release-${{ github.repository }}-${{ github.ref_name }}
2121
cancel-in-progress: false
2222
environment: release
23+
permissions:
24+
contents: write
25+
id-token: write
2326

2427
steps:
2528
- name: Checkout code
@@ -30,7 +33,8 @@ jobs:
3033
- name: Setup Node.js version
3134
uses: actions/setup-node@v6
3235
with:
33-
node-version: 20
36+
node-version: 24
37+
registry-url: 'https://registry.npmjs.org/'
3438

3539
- name: Install node packages
3640
run: yarn install --ci
@@ -42,8 +46,5 @@ jobs:
4246
4347
- name: Generate release
4448
env:
45-
NPM_TOKEN: ${{ secrets.RELEASE_NPM_TOKEN }}
4649
GITHUB_TOKEN: ${{ secrets.RELEASE_GITHUB_TOKEN }}
47-
run: |
48-
echo "//registry.npmjs.org/:_authToken=\${NPM_TOKEN}" > .npmrc
49-
npm run release -- --increment ${{ github.event.inputs.VERSION_BUMP }} -V
50+
run: npm run release -- --increment ${{ github.event.inputs.VERSION_BUMP }} -V

.release-it.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ module.exports = {
1717
`
1818
},
1919
npm: {
20-
publish: true
20+
publish: true,
21+
skipChecks: true
2122
}
2223
};

0 commit comments

Comments
 (0)