mirror of
https://github.com/Vale54321/schafkop-neu.git
synced 2025-12-11 09:59:33 +01:00
refactor GitHub Actions workflow to improve caching
This commit is contained in:
29
.github/workflows/deploy-pages.yml
vendored
29
.github/workflows/deploy-pages.yml
vendored
@@ -28,12 +28,31 @@ jobs:
|
||||
with:
|
||||
targets: wasm32-unknown-unknown
|
||||
|
||||
- name: Cache cargo
|
||||
uses: Swatinem/rust-cache@v2
|
||||
- name: Cache cargo registry and git
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
workspaces: schafkopf-logic
|
||||
cache-directories: |
|
||||
~/.cache/trunk
|
||||
path: |
|
||||
~/.cargo/bin/
|
||||
~/.cargo/registry/index/
|
||||
~/.cargo/registry/cache/
|
||||
~/.cargo/git/db/
|
||||
key: ${{ runner.os }}-cargo-${{ hashFiles('schafkopf-logic/Cargo.toml') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-cargo-
|
||||
|
||||
- name: Cache trunk build artifacts
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cache/trunk/
|
||||
schafkopf-logic/target/wasm-bindgen/
|
||||
schafkopf-logic/target/wasm-opt/
|
||||
schafkopf-logic/target/wasm32-unknown-unknown/
|
||||
~/.cache/.wasm-pack/
|
||||
~/.cache/wasm-pack/
|
||||
key: ${{ runner.os }}-trunk-${{ hashFiles('schafkopf-logic/Cargo.toml') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-trunk-
|
||||
|
||||
- name: Install trunk
|
||||
run: cargo install trunk --locked
|
||||
|
||||
Reference in New Issue
Block a user