@@ -16,14 +16,28 @@ jobs:
16
16
17
17
steps :
18
18
- uses : actions/checkout@v4
19
+
20
+ - name : Cache
21
+ id : rust-cache
22
+ uses : actions/cache@v4
23
+ with :
24
+ path : |
25
+ ~/.cargo/bin/
26
+ ~/.cargo/registry/index/
27
+ ~/.cargo/registry/cache/
28
+ ~/.cargo/git/db/
29
+ target/
30
+ key : ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml', '.github/workflows/*.yml') }}
31
+
19
32
- name : Install packages
20
33
run : |
21
34
sudo apt update
22
35
sudo apt install -y ${{ matrix.libfuse }} build-essential
23
36
24
- - uses : actions-rust-lang/setup-rust-toolchain@v1
25
- with :
26
- target : x86_64-unknown-linux-musl
37
+ - name : Install Rust
38
+ # if: steps.rust-cache.outputs.cache-hit != 'true'
39
+ run : |
40
+ rustup target add x86_64-unknown-linux-musl
27
41
28
42
- name : Run tests
29
43
run : |
@@ -36,18 +50,34 @@ jobs:
36
50
runs-on : ubuntu-22.04
37
51
steps :
38
52
- uses : actions/checkout@v4
53
+
54
+ - name : Cache
55
+ id : rust-cache
56
+ uses : actions/cache@v4
57
+ with :
58
+ path : |
59
+ ~/.cargo/bin/
60
+ ~/.cargo/registry/index/
61
+ ~/.cargo/registry/cache/
62
+ ~/.cargo/git/db/
63
+ target/
64
+ key : ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.toml', '.github/workflows/*.yml') }}
65
+
39
66
- name : Install packages
40
67
run : |
41
68
sudo apt update
42
69
sudo apt install -y libfuse-dev libfuse3-dev build-essential
43
70
44
- - uses : actions-rust-lang/setup-rust-toolchain@v1
45
- with :
46
- components : rustfmt, clippy
71
+ - name : Install Rust
72
+ # if: steps.rust-cache.outputs.cache-hit != 'true'
73
+ run : |
74
+ rustup toolchain install 1.81
75
+ rustup component add rustfmt
76
+ rustup component add clippy
47
77
48
- - uses : taiki-e/install-action@v2
49
- with :
50
-
78
+ - name : Install cargo-deny
79
+ # if: steps.rust-cache.outputs.cache-hit != 'true'
80
+ run : cargo +1.81 install --force --version 0.16.2 cargo-deny --locked
51
81
52
82
- name : Run tests
53
83
run : INTERACTIVE="" make pre
0 commit comments