Fix CI: use Cargo.toml hash for cache key instead of missing Cargo.lock
The previous cache key used hashFiles('**/Cargo.lock') but Cargo.lock is
gitignored in this library repo. This caused the cache to have an empty
hash suffix, restoring stale dependencies that didn't include tantivy,
wide, and other optional deps that were added recently.
Using Cargo.toml hash ensures the cache invalidates when dependencies change.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -36,7 +36,7 @@ jobs:
|
||||
~/.cargo/registry/cache/
|
||||
~/.cargo/git/db/
|
||||
target/
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml') }}
|
||||
|
||||
- name: Build
|
||||
run: cargo build --verbose
|
||||
|
||||
Reference in New Issue
Block a user