File tree Expand file tree Collapse file tree 1 file changed +21
-7
lines changed
Expand file tree Collapse file tree 1 file changed +21
-7
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
1+ # This workflow will run tests using node and then publish a package to NPM when a release is created
22# For more information see: https://docs.github.com/en/actions/publishing-packages/publishing-nodejs-packages
33
44name : Publish Package
77 release :
88 types : [published]
99
10+ permissions :
11+ id-token : write
12+ contents : read
13+
1014jobs :
1115 publish-npm :
1216 runs-on : ubuntu-latest
17+
1318 steps :
14- - uses : actions/checkout@v4
15- - uses : actions/setup-node@v4
19+ - name : 📥 Checkout code
20+ uses : actions/checkout@v4
21+
22+ - name : 🛠 Setup Node.js
23+ uses : actions/setup-node@v4
1624 with :
1725 node-version : ' 20.x'
1826 registry-url : ' https://registry.npmjs.org'
19- - run : npm i
20- - run : npm run build
21- - run : npm publish --access public
27+
28+ - name : 📦 Install dependencies
29+ run : npm ci
30+
31+ - name : 🔨 Build project
32+ run : npm run build
33+
34+ - name : ☁️ Publish to NPM with provenance
35+ run : npm publish --access public --provenance
2236 env :
23- NODE_AUTH_TOKEN : ${{secrets.npm_token}}
37+ NODE_AUTH_TOKEN : ${{ secrets.npm_token }}
You can’t perform that action at this time.
0 commit comments