File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ concurrency:
1010
1111permissions :
1212 contents : write
13+ id-token : write
1314
1415jobs :
1516 release :
2526 with :
2627 bun-version : 1.2.22
2728
29+ - name : Setup Node.js for npm Trusted Publishing
30+ uses : actions/setup-node@v4
31+ with :
32+ node-version : ' 20'
33+ registry-url : ' https://registry.npmjs.org'
34+
2835 - name : Install dependencies
2936 run : bun install --frozen-lockfile
3037
@@ -46,19 +53,11 @@ jobs:
4653 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4754 run : bun run changeset:version
4855
49- - name : Configure npm auth for npmjs
50- if : steps.changesets.outputs.count != '0'
51- env :
52- NODE_AUTH_TOKEN : ${{ secrets.NPM_AUTH_TOKEN }}
53- run : |
54- echo "registry=https://registry.npmjs.org" >> ~/.npmrc
55- echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" >> ~/.npmrc
56-
57- - name : Publish packages
56+ - name : Publish packages (npm trusted publishing)
5857 if : steps.changesets.outputs.count != '0'
5958 env :
6059 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
61- NODE_AUTH_TOKEN : ${{ secrets.NPM_AUTH_TOKEN }}
60+ NPM_CONFIG_PROVENANCE : true
6261 run : bun run changeset:publish
6362
6463 - name : Commit version updates to main
You can’t perform that action at this time.
0 commit comments