Skip to content

Commit c468143

Browse files
authored
ci: Update to version 4 of actions/cache (#24)
1 parent e743c31 commit c468143

File tree

1 file changed

+7
-9
lines changed

1 file changed

+7
-9
lines changed

.github/workflows/rust.yml

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,21 +18,19 @@ jobs:
1818
fail-fast: false
1919
steps:
2020
- uses: actions/checkout@v1
21-
- uses: actions/cache@v3
21+
- uses: actions/cache@v4
22+
id: cache-cargo-fetch
2223
with:
23-
path: |
24-
~/.cargo/bin/
25-
~/.cargo/registry/index/
26-
~/.cargo/registry/cache/
27-
~/.cargo/git/db/
28-
target/
29-
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
24+
key: ${{ runner.os }}-cargo-fetch-${{ hashFiles('Cargo.lock') }}
25+
path: target
26+
restore-keys: ${{ runner.os }}-cargo-fetch
3027
- name: Fetch Dependencies
28+
if: steps.cache-cargo-fetch.outputs.cache-hit != 'true'
3129
run: cargo fetch
3230
- name: Build
3331
run: cargo build --all-features
3432
- name: Run tests
35-
run: cargo test --workspace
33+
run: cargo test
3634

3735
lint:
3836
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)