Skip to content

Commit

Permalink
Add npm release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
orestbida authored Jan 19, 2023
1 parent db5b908 commit afe33c2
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: NPM Registry

on:
release:
types: [published]

jobs:
push-to-npm-registry-as-latest:
if: "!github.event.release.prerelease"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
access: public
tag: latest

push-to-npm-registry-as-next:
if: "github.event.release.prerelease"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
access: public
tag: next

0 comments on commit afe33c2

Please sign in to comment.