From ac46516de4d81d2b4ae8fd9ef649c935d1310f36 Mon Sep 17 00:00:00 2001 From: Jason Hall Date: Sun, 12 Oct 2025 12:03:19 -0400 Subject: [PATCH] Use id token to publish --- .github/workflows/release.yaml | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 2d27405..7c8bd12 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -11,6 +11,8 @@ jobs: publish: name: Publish to crates.io runs-on: ubuntu-latest + permissions: + id-token: write steps: - uses: actions/checkout@v4 @@ -43,5 +45,8 @@ jobs: - name: Run tests run: cargo test --verbose - - name: Publish to crates.io - run: cargo publish --token ${{ secrets.CARGO_TOKEN }} \ No newline at end of file + - uses: rust-lang/crates-io-auth-action@v1 + id: auth + - run: cargo publish + env: + CARGO_REGISTRY_TOKEN: ${{ steps.auth.outputs.token }}