ci: use npm trusted publishing for releases#106
Merged
Conversation
npm now authenticates the publish step via OIDC (trusted publishing) instead of a long-lived NPM_TOKEN. Drop the token env vars and the explicit provenance flag (provenance is automatic under trusted publishing), and upgrade the global npm to >= 11.5.1 since that is the minimum version trusted publishing requires and Node 22 ships npm 10.x.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Switch the release workflow to npm trusted publishing (OIDC) now that it's configured on npmjs.com for the published packages.
NPM_TOKEN/NODE_AUTH_TOKEN— the publish step now authenticates via the OIDCid-tokeninstead of a long-lived token.NPM_CONFIG_PROVENANCE— provenance is generated automatically under trusted publishing.latestbefore publishing — trusted publishing needs npm ≥ 11.5.1, and Node 22 ships npm 10.x.changeset publishshells out to this global npm.Reviewer notes
id-token: writewas already present, so no permissions change was needed..nvmrc.@surfnet/curve-reactand@surfnet/curve-angular, and that the configured workflow filename matchesrelease.yml.NPM_TOKENrepo secret can be deleted once this merges, if nothing else uses it.