Skip to content

Commit 4a18b26

Browse files
shrey150claude
andauthored
[STG-1730] ci: fix release workflow for trusted publishing (#167)
* ci: fix release workflow for trusted publishing - Upgrade setup-node from v4 to v6 for better OIDC support - Add npm upgrade step for trusted publishing compatibility - Remove NPM_CONFIG_PROVENANCE env var (not needed with OIDC) Matches the pattern used in stagehand and openclaw-browserbase repos. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * ci: restore NPM_CONFIG_PROVENANCE for provenance attestation Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * ci: upgrade checkout to v6 with full history, keep provenance - checkout@v4 → v6 with fetch-depth: 0 (changesets needs git history) - Keep NPM_CONFIG_PROVENANCE=true (only way to pass --provenance through changesets) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> * ci: remove NPM_CONFIG_PROVENANCE to match stagehand pattern Stagehand publishes successfully via changesets + OIDC without this env var. Removing it to eliminate the one difference between the two workflows. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 2843e74 commit 4a18b26

File tree

1 file changed

+8
-3
lines changed

1 file changed

+8
-3
lines changed

.github/workflows/release.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,28 +18,33 @@ jobs:
1818
runs-on: ubuntu-latest
1919
steps:
2020
- name: Checkout Repo
21-
uses: actions/checkout@v4
21+
uses: actions/checkout@v6
22+
with:
23+
fetch-depth: 0
2224

2325
- name: Install pnpm
2426
uses: pnpm/action-setup@v4
2527

2628
- name: Setup Node.js
27-
uses: actions/setup-node@v4
29+
uses: actions/setup-node@v6
2830
with:
2931
node-version: "22"
3032
cache: "pnpm"
3133
registry-url: "https://registry.npmjs.org"
3234

35+
- name: Update npm for Trusted Publishing
36+
run: npm install -g npm@latest
37+
3338
- name: Install dependencies
3439
run: pnpm install --frozen-lockfile
3540

3641
- name: Build
3742
run: pnpm build
3843

3944
- name: Create Release Pull Request or Publish to npm
45+
id: changesets
4046
uses: changesets/action@v1
4147
with:
4248
publish: pnpm release
4349
env:
4450
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45-
NPM_CONFIG_PROVENANCE: true

0 commit comments

Comments
 (0)