Skip to content

Commit 971d8c5

Browse files
committed
fix: configure trusted publishing for changesets action
- Use changesets/action@main (includes #545 fix for trusted publishing) - Set NPM_TOKEN to empty string so action doesn't write undefined to .npmrc - Restore registry-url in setup-node (needed for .npmrc creation) - Update npm to latest for trusted publishing support (requires >= 11.5.1)
1 parent 2624413 commit 971d8c5

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,21 @@ jobs:
2424
with:
2525
node-version-file: '.nvmrc'
2626
cache: 'pnpm'
27+
registry-url: 'https://registry.npmjs.org'
28+
29+
- name: Update npm for trusted publishing
30+
run: npm install -g npm@latest
2731

2832
- name: Install dependencies
2933
run: pnpm install --frozen-lockfile
3034

3135
- name: Create Release PR or Publish
32-
uses: changesets/action@v1
36+
uses: changesets/action@main
3337
with:
3438
publish: pnpm changeset publish
3539
title: 'chore: version packages'
3640
commit: 'chore: version packages'
3741
env:
3842
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
NPM_TOKEN: ''
3944
NPM_CONFIG_PROVENANCE: true
40-
NPM_CONFIG_REGISTRY: https://registry.npmjs.org

0 commit comments

Comments
 (0)