Skip to content

Commit

Permalink
Create "publish-to-npm" workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
mrjackyliang authored Feb 17, 2024
1 parent 89b11f3 commit 75433e3
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/publish-to-npm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: "Publish to npm"

run-name: "Publishing ${{ github.event.release.tag_name }} to npm"

on:
release:
types: ["published"]

permissions:
{}

jobs:
publish-to-npm:
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- uses: "actions/setup-node@v4"
with:
node-version-file: "package.json"
registry-url: "https://registry.npmjs.org"
- run: npm install
- run: npm publish
env:
NODE_AUTH_TOKEN: "${{ secrets.NODE_AUTH_TOKEN }}"

0 comments on commit 75433e3

Please sign in to comment.