|
18 | 18 | - name: Install stable toolchain |
19 | 19 | uses: dtolnay/rust-toolchain@stable |
20 | 20 |
|
21 | | - - name: 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.lock') }} |
| 21 | + - name: Set up cache |
| 22 | + uses: Swatinem/rust-cache@v2 |
31 | 23 |
|
32 | 24 | - name: Run cargo check |
33 | 25 | run: cargo check --tests --workspace --benches |
@@ -104,17 +96,6 @@ jobs: |
104 | 96 | with: |
105 | 97 | tool: cargo-nextest |
106 | 98 |
|
107 | | - - name: Cache |
108 | | - uses: actions/cache@v4 |
109 | | - with: |
110 | | - path: | |
111 | | - ~/.cargo/bin/ |
112 | | - ~/.cargo/registry/index/ |
113 | | - ~/.cargo/registry/cache/ |
114 | | - ~/.cargo/git/db/ |
115 | | - target/ |
116 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} |
117 | | - |
118 | 99 | - name: Run cargo build with devnet-prealloc feature |
119 | 100 | run: cargo build --features devnet-prealloc --workspace --all --tests --benches |
120 | 101 |
|
@@ -202,16 +183,8 @@ jobs: |
202 | 183 | with: |
203 | 184 | components: rustfmt, clippy |
204 | 185 |
|
205 | | - - name: Cache |
206 | | - uses: actions/cache@v4 |
207 | | - with: |
208 | | - path: | |
209 | | - ~/.cargo/bin/ |
210 | | - ~/.cargo/registry/index/ |
211 | | - ~/.cargo/registry/cache/ |
212 | | - ~/.cargo/git/db/ |
213 | | - target/ |
214 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} |
| 186 | + - name: Set up cache |
| 187 | + uses: Swatinem/rust-cache@v2 |
215 | 188 |
|
216 | 189 | - name: Run cargo fmt |
217 | 190 | run: cargo fmt --all -- --check |
@@ -261,16 +234,8 @@ jobs: |
261 | 234 | - name: Add wasm32 target |
262 | 235 | run: rustup target add wasm32-unknown-unknown |
263 | 236 |
|
264 | | - - name: Cache |
265 | | - uses: actions/cache@v4 |
266 | | - with: |
267 | | - path: | |
268 | | - ~/.cargo/bin/ |
269 | | - ~/.cargo/registry/index/ |
270 | | - ~/.cargo/registry/cache/ |
271 | | - ~/.cargo/git/db/ |
272 | | - target/ |
273 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} |
| 237 | + - name: Set up cache |
| 238 | + uses: Swatinem/rust-cache@v2 |
274 | 239 |
|
275 | 240 | # append here any new wasm32 crate not already covered by the existing checks |
276 | 241 |
|
@@ -341,16 +306,8 @@ jobs: |
341 | 306 | - name: Install NodeJS dependencies |
342 | 307 | run: npm install --global typedoc typescript |
343 | 308 |
|
344 | | - - name: Cache |
345 | | - uses: actions/cache@v4 |
346 | | - with: |
347 | | - path: | |
348 | | - ~/.cargo/bin/ |
349 | | - ~/.cargo/registry/index/ |
350 | | - ~/.cargo/registry/cache/ |
351 | | - ~/.cargo/git/db/ |
352 | | - target/ |
353 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} |
| 309 | + - name: Set up cache |
| 310 | + uses: Swatinem/rust-cache@v2 |
354 | 311 |
|
355 | 312 | - name: Build wasm release |
356 | 313 | run: | |
@@ -379,19 +336,9 @@ jobs: |
379 | 336 | - name: Install stable toolchain |
380 | 337 | uses: dtolnay/rust-toolchain@stable |
381 | 338 |
|
382 | | - - name: Cache Cargo Build Outputs |
383 | | - uses: actions/cache@v4 |
384 | | - with: |
385 | | - path: | |
386 | | - ~/.cargo/bin/ |
387 | | - ~/.cargo/registry/index/ |
388 | | - ~/.cargo/registry/cache/ |
389 | | - ~/.cargo/git/db/ |
390 | | - target/ |
391 | | - key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }} |
392 | | - restore-keys: | |
393 | | - ${{ runner.os }}-cargo- |
394 | | - |
| 339 | + - name: Set up Rust cache |
| 340 | + uses: Swatinem/rust-cache@v2 |
| 341 | + |
395 | 342 | - name: Cache Toolchain |
396 | 343 | uses: actions/cache@v4 |
397 | 344 | with: |
|
0 commit comments