Skip to content

Commit 4b81ba5

Browse files
Pinank SolankiPinank Solanki
authored andcommitted
Add npm publish github workflow
1 parent d8e3ee2 commit 4b81ba5

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

.github/workflows/npm-publish.yaml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Publish SmartUI Storybook package
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
build:
9+
if: startsWith(github.ref, 'refs/tags/prod-')
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
- uses: actions/setup-node@v2
14+
with:
15+
node-version: 14.15.0
16+
- run: npm install
17+
18+
publish-npm:
19+
needs: build
20+
runs-on: ubuntu-latest
21+
steps:
22+
- uses: actions/checkout@v2
23+
- uses: actions/setup-node@v2
24+
with:
25+
node-version: 14.15.0
26+
registry-url: https://registry.npmjs.org/
27+
- run: npm install
28+
- run: npm publish --access public
29+
env:
30+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

0 commit comments

Comments
 (0)