Skip to content

Commit 4de6e65

Browse files
authored
Merge pull request #37 from github/gp/oidc-migration
Update Node.js version and permissions in publish.yml
2 parents 6fd8c17 + 4829657 commit 4de6e65

2 files changed

Lines changed: 15 additions & 15 deletions

File tree

.github/workflows/publish.yml

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,39 +7,39 @@ on:
77
jobs:
88
publish-npm:
99
runs-on: ubuntu-latest
10+
permissions:
11+
contents: read
12+
id-token: write
1013
steps:
11-
- uses: actions/checkout@v3
12-
- uses: actions/setup-node@v3
14+
- uses: actions/checkout@v5
15+
- uses: actions/setup-node@v5
1316
with:
14-
node-version: 14
17+
node-version: 24
1518
registry-url: https://registry.npmjs.org/
1619
cache: npm
1720
- run: npm ci
1821
- run: npm test
1922
- run: npm version ${TAG_NAME} --git-tag-version=false
2023
env:
2124
TAG_NAME: ${{ github.event.release.tag_name }}
22-
- run: npm whoami; npm --ignore-scripts publish
23-
env:
24-
NODE_AUTH_TOKEN: ${{secrets.npm_token}}
25+
- run: npm --ignore-scripts publish --provenance
2526

2627
publish-github:
2728
runs-on: ubuntu-latest
2829
permissions:
2930
contents: read
3031
packages: write
32+
id-token: write
3133
steps:
32-
- uses: actions/checkout@v3
33-
- uses: actions/setup-node@v3
34+
- uses: actions/checkout@v5
35+
- uses: actions/setup-node@v5
3436
with:
35-
node-version: 14
37+
node-version: 24
3638
registry-url: https://npm.pkg.github.com
3739
cache: npm
3840
- run: npm ci
3941
- run: npm test
4042
- run: npm version ${TAG_NAME} --git-tag-version=false
4143
env:
4244
TAG_NAME: ${{ github.event.release.tag_name }}
43-
- run: npm whoami; npm --ignore-scripts publish
44-
env:
45-
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
- run: npm --ignore-scripts publish --provenance

.github/workflows/test.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,10 @@ jobs:
77
runs-on: ubuntu-latest
88
steps:
99
- uses: actions/checkout@v2
10-
- name: Use Node.js 18.x
11-
uses: actions/setup-node@v1
10+
- name: Use Node.js 24.x
11+
uses: actions/setup-node@v5
1212
with:
13-
node-version: 18.x
13+
node-version: 24.x
1414
- name: npm install, build, and test
1515
run: |
1616
npm it

0 commit comments

Comments
 (0)