Skip to content

Commit 46708bf

Browse files
author
Bart Veneman
committed
fix release script
1 parent cacb906 commit 46708bf

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

.github/workflows/release.yml

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,34 @@
11
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
22
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages
33

4-
name: Publish
4+
name: NPM Publish
5+
56
on:
67
release:
78
types: [created]
9+
810
jobs:
911
build:
1012
runs-on: ubuntu-latest
1113
steps:
1214
- uses: actions/checkout@v2
13-
# Setup .npmrc file to publish to npm
1415
- uses: actions/setup-node@v2
1516
with:
16-
node-version: '16.x'
17+
node-version: 16
18+
- run: npm ci
19+
- run: npm test
20+
21+
publish-npm:
22+
needs: build
23+
runs-on: ubuntu-latest
24+
steps:
25+
- uses: actions/checkout@v2
26+
- uses: actions/setup-node@v2
27+
with:
28+
node-version: 16
1729
registry-url: https://registry.npmjs.org/
1830
- run: npm ci
31+
- run: npm run build
1932
- run: npm publish
2033
env:
2134
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

0 commit comments

Comments
 (0)