Skip to content

Commit 85576e4

Browse files
ind-igoclaude
andcommitted
Let cargo handle OIDC token exchange natively
Manual token generation was producing tokens crates.io rejected. Cargo 1.84+ handles trusted publishing automatically when CARGO_REGISTRY_TOKEN is empty and id-token permission is set. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 22d8685 commit 85576e4

1 file changed

Lines changed: 1 addition & 8 deletions

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -77,16 +77,9 @@ jobs:
7777
steps:
7878
- uses: actions/checkout@v4
7979
- uses: dtolnay/rust-toolchain@stable
80-
- name: Generate OIDC token
81-
id: oidc
82-
run: |
83-
token=$(curl -sS -H "Authorization: bearer $ACTIONS_ID_TOKEN_REQUEST_TOKEN" \
84-
"$ACTIONS_ID_TOKEN_REQUEST_URL&audience=crates.io" | jq -r '.value')
85-
echo "::add-mask::$token"
86-
echo "token=$token" >> "$GITHUB_OUTPUT"
8780
- run: cargo publish
8881
env:
89-
CARGO_REGISTRY_TOKEN: "oidc:${{ steps.oidc.outputs.token }}"
82+
CARGO_REGISTRY_TOKEN: ""
9083

9184
update-homebrew:
9285
needs: release

0 commit comments

Comments
 (0)