File tree Expand file tree Collapse file tree 1 file changed +7
-10
lines changed
Expand file tree Collapse file tree 1 file changed +7
-10
lines changed Original file line number Diff line number Diff line change 11name : NPM publish
22on :
33 workflow_call :
4- secrets :
5- NPM_TOKEN :
6- required : true
74jobs :
85 build :
96 name : ' npm publish'
107 runs-on : ubuntu-latest
118 environment : production
9+ permissions :
10+ id-token : write
11+ contents : read
1212 steps :
1313 - name : ' Checkout source code'
1414 uses : ' actions/checkout@v3'
@@ -18,19 +18,16 @@ jobs:
1818 - name : ' Show current version'
1919 run : grep '"version"' package.json
2020
21- # Setup .npmrc file to publish to npm
2221 - name : Setup Node.js environment
2322 uses : actions/setup-node@v3
2423 with :
25- node-version : ' 16 .x'
24+ node-version : ' 20 .x'
2625 always-auth : true
2726 scope : ' @openbeta'
2827 registry-url : ' https://registry.npmjs.org'
2928
30- - run : echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" >> ~/.npmrc
29+ - name : Update npm
30+ run : npm install -g npm@11
3131
3232 - name : NPM publish
33- run : yarn install --no-progress && yarn lint && yarn test && yarn build && yarn publish --access public
34- env :
35- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
36-
33+ run : yarn install --no-progress && yarn lint && yarn test && yarn build && npm publish --provenance --access public
You can’t perform that action at this time.
0 commit comments