fix: add caching for Cargo registry and build artifacts in Tauri workflow
This commit is contained in:
64
.github/workflows/tauri.yml
vendored
64
.github/workflows/tauri.yml
vendored
@@ -21,6 +21,20 @@ jobs:
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
components: llvm-tools-preview
|
||||
- name: Cache Cargo registry
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
key: cargo-registry-${{ runner.os }}
|
||||
restore-keys: cargo-registry-
|
||||
- name: Cache Cargo build
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: src-tauri/target
|
||||
key: cargo-build-windows-${{ runner.os }}
|
||||
restore-keys: cargo-build-windows-
|
||||
- name: Install cinny dependencies
|
||||
run: cd cinny && npm ci
|
||||
- name: Install tauri dependencies
|
||||
@@ -76,6 +90,20 @@ jobs:
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
components: llvm-tools-preview
|
||||
- name: Cache Cargo registry
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
key: cargo-registry-${{ runner.os }}
|
||||
restore-keys: cargo-registry-
|
||||
- name: Cache Cargo build
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: src-tauri/target
|
||||
key: cargo-build-linux-${{ runner.os }}
|
||||
restore-keys: cargo-build-linux-
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
@@ -130,6 +158,20 @@ jobs:
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
target: aarch64-apple-darwin,x86_64-apple-darwin
|
||||
- name: Cache Cargo registry
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
key: cargo-registry-${{ runner.os }}
|
||||
restore-keys: cargo-registry-
|
||||
- name: Cache Cargo build
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: src-tauri/target
|
||||
key: cargo-build-macos-${{ runner.os }}
|
||||
restore-keys: cargo-build-macos-
|
||||
- name: Install cinny dependencies
|
||||
run: cd cinny && npm ci
|
||||
- name: Install tauri dependencies
|
||||
@@ -185,6 +227,28 @@ jobs:
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
targets: aarch64-linux-android
|
||||
- name: Cache Cargo registry
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.cargo/registry
|
||||
~/.cargo/git
|
||||
key: cargo-registry-${{ runner.os }}
|
||||
restore-keys: cargo-registry-
|
||||
- name: Cache Cargo build
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: src-tauri/target
|
||||
key: cargo-build-android-${{ runner.os }}
|
||||
restore-keys: cargo-build-android-
|
||||
- name: Cache Gradle
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: |
|
||||
~/.gradle/caches
|
||||
~/.gradle/wrapper
|
||||
key: gradle-${{ runner.os }}
|
||||
restore-keys: gradle-
|
||||
- name: Install NDK
|
||||
run: sdkmanager "ndk;27.0.11902837"
|
||||
- name: Install cinny dependencies
|
||||
|
||||
Reference in New Issue
Block a user