Skip to content

Commit fd913a8

Browse files
authored
Automate Publish to NPM (#4)
- initial publish workflow
1 parent 37a6838 commit fd913a8

1 file changed

Lines changed: 27 additions & 0 deletions

File tree

.github/workflows/publish.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Publish
2+
3+
on:
4+
release:
5+
types:
6+
- published
7+
workflow_dispatch:
8+
9+
jobs:
10+
build:
11+
name: Build
12+
13+
runs-on: ubuntu-latest
14+
timeout-minutes: 5
15+
16+
steps:
17+
- uses: actions/checkout@v3
18+
- uses: actions/setup-node@v3
19+
with:
20+
node-version-file: '.nvmrc'
21+
cache: 'npm'
22+
registry-url: 'https://registry.npmjs.org'
23+
- run: npm ci
24+
- run: num run build
25+
- run: npm publish
26+
env:
27+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)