Skip to content

Commit

Permalink
chore: allow publishing prereleases (#295)
Browse files Browse the repository at this point in the history
  • Loading branch information
43081j committed May 14, 2024
1 parent 7e2b1a9 commit c9a4b22
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ name: Publish to npm

on:
release:
types: [created]
types: [published]

jobs:
build:
Expand Down Expand Up @@ -35,6 +35,11 @@ jobs:
- run: npm version ${TAG_NAME} --git-tag-version=false
env:
TAG_NAME: ${{ github.ref_name }}
- run: npm publish --provenance --access public --tag next
if: "github.event.release.prerelease"
env:
NODE_AUTH_TOKEN: ${{ secrets.npm_secret }}
- run: npm publish --provenance --access public
if: "!github.event.release.prerelease"
env:
NODE_AUTH_TOKEN: ${{ secrets.npm_secret }}

0 comments on commit c9a4b22

Please sign in to comment.