From 3a5327f5b1f2f9c1175802fed823aa4c7157bd00 Mon Sep 17 00:00:00 2001 From: Christian Visintin Date: Mon, 8 Jun 2026 19:16:58 +0200 Subject: [PATCH] ci(release): fetch full git history and tags for build.rs build.rs uses vergen-git2 (Git2::all_git), which runs `git describe` and reads commit metadata. The build and publish-crate jobs checked out a shallow clone without tags, so vergen could not resolve the describe string and libgit2 may fail on shallow repos. Add fetch-depth: 0 and fetch-tags: true to both jobs that compile the crate. --- .github/workflows/release.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3f633dc..84f78f5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -115,6 +115,8 @@ jobs: with: ref: ${{ inputs.dry_run && github.sha || 'main' }} persist-credentials: false + fetch-depth: 0 + fetch-tags: true - uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable with: targets: ${{ matrix.target }} @@ -382,6 +384,8 @@ jobs: with: ref: main persist-credentials: false + fetch-depth: 0 + fetch-tags: true - uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable - name: Install dependencies (Linux)