mirror of
https://github.com/rust-unofficial/awesome-rust
synced 2024-11-22 11:53:06 +00:00
Use github run_id as "random" key
This commit is contained in:
parent
64ccfe3e52
commit
aeac71fdfb
1 changed files with 1 additions and 4 deletions
5
.github/workflows/rust.yml
vendored
5
.github/workflows/rust.yml
vendored
|
@ -20,15 +20,12 @@ jobs:
|
|||
toolchain: stable
|
||||
components: rustfmt
|
||||
- uses: Swatinem/rust-cache@v2
|
||||
- name: Get random cache id
|
||||
run: echo "CACHE_ID=$((RANDOM))" >> $GITHUB_ENV
|
||||
shell: bash
|
||||
- name: Load rust cache
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
save-always: true
|
||||
path: results/*.yaml
|
||||
key: results-${{ hashFiles('Cargo.lock') }}-${{ hashFiles('README.md') }}-${{ env.CACHE_ID }}
|
||||
key: results-${{ hashFiles('Cargo.lock') }}-${{ hashFiles('README.md') }}-${{ github.run_id }}
|
||||
restore-keys: |
|
||||
results-${{ hashFiles('Cargo.lock') }}-${{ hashFiles('README.md') }}-
|
||||
results-${{ hashFiles('Cargo.lock') }}-
|
||||
|
|
Loading…
Reference in a new issue