Skip to content

Commit

Permalink
Add GitHub Actions workflow for publishing to NPM on release
Browse files Browse the repository at this point in the history
  • Loading branch information
MasatoMakino committed Dec 23, 2024
1 parent e516c32 commit abf77de
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/npm_publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Publish to NPM
on:
release:
types: [created]
jobs:
npm-publish:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: "20"
cache: "npm"
registry-url: "https://registry.npmjs.org"
- run: npm ci
- name: build binary
run: npm run buildTS
- name: Publish package on NPM 📦
run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}

0 comments on commit abf77de

Please sign in to comment.