Repository navigation
Use a crates.io API token for the release workflow - #43
Merged
Merged
Conversation
Trusted Publishing requires a one-time OIDC setup on the crates.io crate settings, which is more ceremony than is warranted right now. Switch to a CARGO_REGISTRY_TOKEN secret, which only needs to be pasted into the repository settings. - Publish using the CARGO_REGISTRY_TOKEN secret instead of obtaining a short-lived token via rust-lang/crates-io-auth-action. - Drop the now-unneeded id-token: write permission. - Fail fast when the secret is missing, rather than after the ~230 MB model download and full test run. - Document the token setup, and keep Trusted Publishing documented as the alternative for whenever we want to stop storing a long-lived credential. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
complexsplit
approved these changes
Sep 29, 2026
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.
Follow-up to #42.
Trusted Publishing needs a one-time OIDC configuration on the crates.io crate settings page. That's more ceremony than is warranted for getting 0.3.0 out, so this switches the release workflow to a plain
CARGO_REGISTRY_TOKENsecret — the only setup is pasting a token into repository settings.Changes
CARGO_REGISTRY_TOKENsecret instead of obtaining a short-lived token viarust-lang/crates-io-auth-action.id-token: writepermission.rust/RELEASING.md, and keep Trusted Publishing documented as the alternative for whenever we want to stop storing a long-lived credential.The
crates-ioenvironment is retained, and the docs now recommend storing the token as an environment secret rather than a repository secret, so it's only exposed to jobs that opt into that environment — and so a required-reviewer rule can be added later if desired.Setup required before the first automated release
publish-update, restricted to thetrustmarkcrate.crates-ioenvironment under Settings → Environments (the repo currently has none).CARGO_REGISTRY_TOKENsecret on that environment.Validation