-
-
Notifications
You must be signed in to change notification settings - Fork 90
38 lines (34 loc) · 832 Bytes
/
publish.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: publish
on: [workflow_dispatch]
jobs:
build:
name: Build artifacts
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2.5.1
with:
node-version: 14.x
- run: npm ci
- run: npm run lint
- run: npm run build
- uses: actions/upload-artifact@v2
with:
name: dist
path: dist
publish:
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2.5.1
with:
node-version: 14.x
registry-url: https://registry.npmjs.org/
- uses: actions/download-artifact@v2
with:
name: dist
path: dist
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.npm_token}}