Skip to content

Commit

Permalink
Merge pull request #20 from github/gracepark-actions-maintenance
Browse files Browse the repository at this point in the history
Upgrade node to 22 and add provenance
  • Loading branch information
gracepark authored Oct 24, 2024
2 parents 3cbbeef + 1cef1bc commit 613b91a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
name: Node.js CI
on: [push]
permissions:
contents: read
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: '18.x'
node-version: '22.x'
- run: npm install
- run: npm run build --if-present
- run: npm test
Expand Down
12 changes: 8 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,25 @@ on:
release:
types: [created]

permissions:
contents: read
id-token: write

jobs:
publish-npm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 14
node-version: 22
registry-url: https://registry.npmjs.org/
cache: npm
- run: npm ci
- run: npm test
- run: npm version ${TAG_NAME} --git-tag-version=false
env:
TAG_NAME: ${{ github.event.release.tag_name }}
- run: npm whoami; npm --ignore-scripts publish
- run: npm whoami; npm --ignore-scripts publish --provenance
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}

0 comments on commit 613b91a

Please sign in to comment.