Skip to content

Commit 853fa8b

Browse files
authored
Speedup regenerate-target-info and regenerate-windows-sys (#1110)
Create lockfile so that rust-cache knows if a new cache needs to be saved. Also enables cache-all-crates since the crates themselves rarely changes.
1 parent bcb7cbe commit 853fa8b

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

.github/workflows/regenerate-target-info.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,13 @@ jobs:
2121
- name: Install rust
2222
run: |
2323
rustup toolchain install stable nightly --no-self-update --profile minimal
24+
25+
- name: Create lockfile
26+
run: cargo update
2427

2528
- uses: Swatinem/rust-cache@v2
29+
with:
30+
cache-all-crates: 'true'
2631
- name: Regenerate target info
2732
run: cargo run -p gen-target-info
2833

.github/workflows/regenerate-windows-sys.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,13 @@ jobs:
1818
run: |
1919
git checkout -b regenerate-windows-sys-${{ github.run_id }}
2020
21+
- name: Create lockfile
22+
run: cargo update
23+
2124
- uses: Swatinem/rust-cache@v2
25+
with:
26+
cache-all-crates: 'true'
27+
2228
- name: Regenerate windows sys bindings
2329
run: cargo run -p gen-windows-sys-binding
2430

0 commit comments

Comments
 (0)