Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 15 additions & 5 deletions .github/workflows/deploy.yml → .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ on:
tags:
- v*

permissions:
id-token: write
contents: write

jobs:
deploy:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -59,10 +63,16 @@ jobs:
git push origin main
git push origin ${{ steps.version.outputs.current-version }}

- name: Setup Node.js for NPM publish
uses: actions/setup-node@v4
with:
node-version: "20"
registry-url: "https://registry.npmjs.org"

- name: Update npm for OIDC support
run: npm install -g npm@latest

- name: Publish to NPM
run: |
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > ~/.npmrc
echo "//registry.npmjs.org/:always-auth=true" >> ~/.npmrc
npm publish
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_CONFIG_PROVENANCE: true
run: npm publish --provenance