File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,10 +18,13 @@ jobs:
1818 steps :
1919 - uses : actions/checkout@v6
2020 - uses : dtolnay/rust-toolchain@stable
21+ - name : Get cache week
22+ id : cache-week
23+ run : echo "week=$(date +%Y-%W)" >> $GITHUB_OUTPUT
24+ shell : bash
2125 - uses : Swatinem/rust-cache@v2
2226 with :
23- prefix-key : " v1-rust"
24- shared-key : " ${{ inputs.os }}"
27+ shared-key : " ${{ steps.cache-week.outputs.week }}-${{ inputs.os }}"
2528 cache-on-failure : true
2629 - name : Build workspace
2730 run : cargo build --workspace --all-targets --all-features ${{ inputs.exclude-crates && format('--exclude {0}', inputs.exclude-crates) || '' }}
@@ -37,10 +40,13 @@ jobs:
3740 steps :
3841 - uses : actions/checkout@v6
3942 - uses : dtolnay/rust-toolchain@stable
43+ - name : Get cache week
44+ id : cache-week
45+ run : echo "week=$(date +%Y-%W)" >> $GITHUB_OUTPUT
46+ shell : bash
4047 - uses : Swatinem/rust-cache@v2
4148 with :
42- prefix-key : " v1-rust"
43- shared-key : " ${{ inputs.os }}"
49+ shared-key : " ${{ steps.cache-week.outputs.week }}-${{ inputs.os }}"
4450 save-if : false
4551 - uses : actions/setup-python@v5
4652 with :
You can’t perform that action at this time.
0 commit comments