File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1919 toolchain : stable
2020 components : clippy, rustfmt
2121
22+ # The crate lives in src-tauri, not the repo root, so point the cache at it
23+ # or it finds no Cargo.lock and silently caches nothing. Tauri pulls a large
24+ # dependency tree and compiling it from scratch was the whole 19 minutes.
25+ # The key is separate from the release job's: this one holds dev profile
26+ # artifacts, that one holds the optimized profile, and they do not overlap.
27+ - uses : Swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.9.1
28+ with :
29+ workspaces : src-tauri
30+ shared-key : ci-dev
31+ # Pull requests restore the cache but do not write one, so a branch
32+ # cannot evict main's entry with its own half built tree.
33+ save-if : ${{ github.ref == 'refs/heads/main' }}
34+
2235 # No setup-node: windows-latest already ships a Node new enough for Vite
2336 # and for the node --test style suites, so this is one less action to pin.
2437 - name : Frontend
Original file line number Diff line number Diff line change 2020 toolchain : stable
2121 components : clippy, rustfmt
2222
23+ # A separate key from CI's on purpose: this job compiles the optimized
24+ # profile with lto and opt-level z, so it shares almost no artifacts with
25+ # the dev profile CI caches. Tags are infrequent, but dependencies change
26+ # far less often than tags do, so the entry usually survives release to
27+ # release. Always saves: there is no branch here to protect main from.
28+ - uses : Swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.9.1
29+ with :
30+ workspaces : src-tauri
31+ shared-key : release-opt
32+
2333 # Without the signing key the build still produces an installer, then fails
2434 # at the very end when it cannot write the updater signature. That wastes a
2535 # full Tauri release build, so refuse up front with a message that says what
You can’t perform that action at this time.
0 commit comments