Skip to content

Commit

Permalink
Speedup regenerate-target-info and regenerate-windows-sys (#1110)
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
NobodyXu committed Jun 27, 2024
1 parent bcb7cbe commit 853fa8b
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/regenerate-target-info.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,13 @@ jobs:
- name: Install rust
run: |
rustup toolchain install stable nightly --no-self-update --profile minimal
- name: Create lockfile
run: cargo update

- uses: Swatinem/rust-cache@v2
with:
cache-all-crates: 'true'
- name: Regenerate target info
run: cargo run -p gen-target-info

Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/regenerate-windows-sys.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,13 @@ jobs:
run: |
git checkout -b regenerate-windows-sys-${{ github.run_id }}
- name: Create lockfile
run: cargo update

- uses: Swatinem/rust-cache@v2
with:
cache-all-crates: 'true'

- name: Regenerate windows sys bindings
run: cargo run -p gen-windows-sys-binding

Expand Down

0 comments on commit 853fa8b

Please sign in to comment.