Skip to content

Commit ebe0776

Browse files
authored
feat: add prerelease workflow (#257)
* feat: add prerelease workflow * fix: remove rc preid
1 parent 7c2b8c7 commit ebe0776

File tree

2 files changed

+23
-3
lines changed

2 files changed

+23
-3
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: npm Package
2+
3+
on:
4+
release:
5+
types: [prereleased]
6+
7+
jobs:
8+
publish-npm:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v2
12+
- uses: actions/setup-node@v2
13+
with:
14+
node-version: "14"
15+
registry-url: "https://registry.npmjs.org"
16+
- run: npm ci
17+
- run: npm --no-git-tag-version version ${{ github.event.release.tag_name }}
18+
- run: npm publish --access public --tag next
19+
env:
20+
NODE_AUTH_TOKEN: ${{ secrets.npm_token }}

.github/workflows/npm-publish.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ jobs:
99
runs-on: ubuntu-latest
1010
steps:
1111
- uses: actions/checkout@v2
12-
- uses: actions/setup-node@v1
12+
- uses: actions/setup-node@v2
1313
with:
14-
node-version: 14
15-
registry-url: https://registry.npmjs.org/
14+
node-version: "14"
15+
registry-url: "https://registry.npmjs.org"
1616
- run: npm ci
1717
- run: npm --no-git-tag-version version ${{ github.event.release.tag_name }}
1818
- run: npm publish --access public

0 commit comments

Comments
 (0)