File tree Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Expand file tree Collapse file tree 1 file changed +36
-0
lines changed Original file line number Diff line number Diff line change 1+ # This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
2+ # For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
3+
4+ name : Node.js Package
5+
6+ on :
7+ release :
8+ types : [published]
9+
10+ permissions :
11+ contents : read
12+
13+ jobs :
14+ build :
15+ runs-on : ubuntu-latest
16+ steps :
17+ - uses : actions/checkout@v4
18+ - uses : actions/setup-node@v4
19+ with :
20+ node-version : 20
21+ - run : npm ci
22+ - run : npm test
23+
24+ publish-npm :
25+ needs : build
26+ runs-on : ubuntu-latest
27+ steps :
28+ - uses : actions/checkout@v4
29+ - uses : actions/setup-node@v4
30+ with :
31+ node-version : 20
32+ registry-url : https://registry.npmjs.org/
33+ - run : npm ci
34+ - run : npm publish --provenance --access public
35+ env :
36+ NODE_AUTH_TOKEN : ${{secrets.npm_token}}
You can’t perform that action at this time.
0 commit comments