Skip to content

Commit c903b92

Browse files
authored
chore(release): update release action (#140)
1 parent e45c135 commit c903b92

1 file changed

Lines changed: 12 additions & 3 deletions

File tree

.github/workflows/CD_release_npm.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,20 +10,30 @@ on:
1010
jobs:
1111
runCI:
1212
uses: ./.github/workflows/CI_PR_merge_checks.yml
13+
1314
releaseAndBumpVersion:
1415
needs: runCI
1516
name: Publish the package
1617
runs-on: ubuntu-latest
1718

19+
permissions:
20+
contents: write
21+
id-token: write
22+
1823
steps:
19-
- uses: actions/checkout@v2
24+
- uses: actions/checkout@v4
25+
with:
26+
fetch-depth: 0
2027

2128
- name: Use Node.js 20
22-
uses: actions/setup-node@v1
29+
uses: actions/setup-node@v4
2330
with:
2431
node-version: 20
2532
registry-url: https://registry.npmjs.org/
2633

34+
- name: Upgrade npm CLI for trusted publishing
35+
run: npm i -g npm@^11.5.1
36+
2737
- name: Configure Github credentials
2838
run: |
2939
git config --global user.name "Github"
@@ -39,5 +49,4 @@ jobs:
3949
npx semantic-release
4050
env:
4151
HUSKY: 0
42-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
4352
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)