Skip to content

ci: upgrade @semantic-release/npm to v13.1 for native OIDC support#36

Merged
rome2o merged 1 commit into
mainfrom
fix/oidc-npm-v2
May 14, 2026
Merged

ci: upgrade @semantic-release/npm to v13.1 for native OIDC support#36
rome2o merged 1 commit into
mainfrom
fix/oidc-npm-v2

Conversation

@rome2o

@rome2o rome2o commented May 14, 2026

Copy link
Copy Markdown
Member

Summary

  • Upgrades @semantic-release/npm from ^12.0.2^13.1.0 — this version natively handles npm Trusted Publisher OIDC, replacing the broken npm whoami check
  • Removes registry-url from setup-node — it was injecting NODE_AUTH_TOKEN and blocking OIDC
  • Removes the manual OIDC curl token exchange step (was returning null)
  • Adds npm install -g npm@latest to ensure npm >= 11.5.1 (required for OIDC exchange)
  • Sets NODE_AUTH_TOKEN: "" explicitly in the release step to clear any injected value
  • Adds provenance: true to publishConfig in package.json

Why

The previous approach tried to manually exchange OIDC tokens via curl — that endpoint isn't publicly documented and returned null. @semantic-release/npm v13.1.0+ handles the OIDC exchange natively using GitHub Actions' id-token: write permission. No stored NPM_TOKEN required.

References

🤖 Generated with Claude Code

- Bump @semantic-release/npm from ^12.0.2 to ^13.1.0 (native npm OIDC — no NPM_TOKEN needed)
- Remove registry-url from setup-node to prevent NODE_AUTH_TOKEN injection blocking OIDC
- Remove manual OIDC curl token exchange step (now handled natively by the plugin)
- Add NODE_AUTH_TOKEN: "" in Semantic Release step to explicitly clear any injected value
- Add npm install -g npm@latest step to ensure npm >= 11.5.1
- Add provenance: true to publishConfig for npm attestations

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@rome2o rome2o merged commit a6548de into main May 14, 2026
1 check passed
@github-actions

Copy link
Copy Markdown

🎉 This PR is included in version 1.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant