Skip to content
37 changes: 24 additions & 13 deletions .github/workflows/android-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,22 +61,23 @@ jobs:
restore-keys: |
${{ runner.os }}-gradle-

- name: Rust Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true

- name: Cache Cargo registry
- name: Install sccache
run: |
SCCACHE_VERSION=0.8.2
SCCACHE_URL="https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl.tar.gz"
curl -L "$SCCACHE_URL" | tar xz
sudo mv sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl/sccache /usr/local/bin/
chmod +x /usr/local/bin/sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache-android-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-registry-
${{ runner.os }}-sccache-android-
${{ runner.os }}-sccache-

- name: Cache Cargo bin
uses: actions/cache@v4
Expand Down Expand Up @@ -142,6 +143,13 @@ jobs:

echo "Generated tauri.properties with version $VERSION and versionCode $VERSION_CODE"

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_DIR=$HOME/.cache/sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats

- name: Build Tauri Android App (Signed Release)
working-directory: ./frontend
run: |
Expand Down Expand Up @@ -184,6 +192,9 @@ jobs:
VITE_MAPLE_BILLING_API_URL: ${{ github.event_name == 'pull_request' && 'https://billing-dev.opensecret.cloud' || 'https://billing.opensecret.cloud' }}
VITE_CLIENT_ID: ba5a14b5-d915-47b1-b7b1-afda52bc5fc6

- name: Show sccache stats
run: sccache --show-stats

- name: Upload Android APK
uses: actions/upload-artifact@v4
with:
Expand Down
38 changes: 23 additions & 15 deletions .github/workflows/claude.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,23 @@ jobs:
with:
targets: aarch64-apple-darwin,x86_64-apple-darwin,aarch64-apple-ios

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache
run: |
SCCACHE_VERSION=0.8.2
SCCACHE_URL="https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl.tar.gz"
curl -L "$SCCACHE_URL" | tar xz
sudo mv sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl/sccache /usr/local/bin/
chmod +x /usr/local/bin/sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache-claude-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-claude-
${{ runner.os }}-sccache-

- name: Cache APT packages
uses: actions/cache@v4
Expand All @@ -101,17 +113,6 @@ jobs:
working-directory: ./frontend
run: bun install

- name: Cache Cargo registry
uses: actions/cache@v4
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-registry-

- name: Cache Cargo bin
uses: actions/cache@v4
with:
Expand All @@ -120,6 +121,13 @@ jobs:
restore-keys: |
${{ runner.os }}-cargo-bin-

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_DIR=$HOME/.cache/sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats

- name: Install Tauri CLI
run: |
if ! command -v cargo-tauri &> /dev/null; then
Expand Down
49 changes: 41 additions & 8 deletions .github/workflows/desktop-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,19 @@ jobs:
with:
targets: aarch64-apple-darwin,x86_64-apple-darwin

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache
run: |
brew install sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ~/Library/Caches/Mozilla.sccache
key: ${{ runner.os }}-sccache-macos-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-macos-
${{ runner.os }}-sccache-

- name: Install dependencies (macOS)
run: |
Expand All @@ -39,6 +47,12 @@ jobs:
working-directory: ./frontend
run: bun install

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats
Comment thread
AnthonyRonning marked this conversation as resolved.
Outdated

- name: Import Apple Developer Certificate
env:
APPLE_CERTIFICATE: ${{ secrets.APPLE_CERTIFICATE }}
Expand Down Expand Up @@ -102,11 +116,23 @@ jobs:
- name: Install Rust
uses: dtolnay/rust-toolchain@stable

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache
run: |
SCCACHE_VERSION=0.8.2
SCCACHE_URL="https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl.tar.gz"
curl -L "$SCCACHE_URL" | tar xz
sudo mv sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl/sccache /usr/local/bin/
chmod +x /usr/local/bin/sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache-linux-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-linux-
${{ runner.os }}-sccache-

- name: Install Linux dependencies
run: |
Expand All @@ -130,6 +156,13 @@ jobs:
env:
CARGO_CFG_TARGET_OS: linux

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_DIR=$HOME/.cache/sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats

- name: Build Tauri App (Linux)
working-directory: ./frontend
run: cargo tauri build
Expand Down
22 changes: 18 additions & 4 deletions .github/workflows/mobile-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,19 @@ jobs:
with:
targets: aarch64-apple-ios

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache
run: |
brew install sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ~/Library/Caches/Mozilla.sccache
key: ${{ runner.os }}-sccache-ios-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-ios-
${{ runner.os }}-sccache-

- name: Install dependencies (macOS)
run: |
Expand Down Expand Up @@ -54,6 +62,12 @@ jobs:
echo "${{ secrets.APPLE_API_PRIVATE_KEY }}" | base64 --decode > ~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8
chmod 600 ~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8
echo "APPLE_API_KEY_PATH=~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8" >> $GITHUB_ENV

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats
Comment thread
AnthonyRonning marked this conversation as resolved.
Outdated

- name: Build Tauri iOS App
working-directory: ./frontend
Expand Down
67 changes: 50 additions & 17 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,30 @@ jobs:
with:
targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }}

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache (macOS)
if: matrix.platform == 'macos-latest'
run: |
brew install sccache
sccache --version

- name: Install sccache (Linux)
if: matrix.platform == 'ubuntu-latest'
run: |
SCCACHE_VERSION=0.8.2
SCCACHE_URL="https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl.tar.gz"
curl -L "$SCCACHE_URL" | tar xz
sudo mv sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl/sccache /usr/local/bin/
chmod +x /usr/local/bin/sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ${{ matrix.platform == 'macos-latest' && '~/Library/Caches/Mozilla.sccache' || '~/.cache/sccache' }}
key: ${{ runner.os }}-sccache-release-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-release-
${{ runner.os }}-sccache-

- name: Install dependencies (macOS)
if: matrix.platform == 'macos-latest'
Expand All @@ -78,6 +97,12 @@ jobs:
working-directory: ./frontend
run: bun install

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats
Comment thread
AnthonyRonning marked this conversation as resolved.
Outdated

- name: Build Tauri App
uses: tauri-apps/tauri-action@v0
env:
Expand Down Expand Up @@ -157,22 +182,23 @@ jobs:
restore-keys: |
${{ runner.os }}-gradle-

- name: Rust Cache
uses: Swatinem/rust-cache@v2
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true

- name: Cache Cargo registry
- name: Install sccache
run: |
SCCACHE_VERSION=0.8.2
SCCACHE_URL="https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl.tar.gz"
curl -L "$SCCACHE_URL" | tar xz
sudo mv sccache-v${SCCACHE_VERSION}-x86_64-unknown-linux-musl/sccache /usr/local/bin/
chmod +x /usr/local/bin/sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
path: |
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
path: ~/.cache/sccache
key: ${{ runner.os }}-sccache-android-release-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-registry-
${{ runner.os }}-sccache-android-release-
${{ runner.os }}-sccache-

- name: Cache Cargo bin
uses: actions/cache@v4
Expand Down Expand Up @@ -238,6 +264,13 @@ jobs:

echo "Generated tauri.properties with version $VERSION and versionCode $VERSION_CODE"

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_DIR=$HOME/.cache/sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats

- name: Build Tauri Android App (Signed Release)
working-directory: ./frontend
run: |
Expand Down
22 changes: 18 additions & 4 deletions .github/workflows/testflight-on-comment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,19 @@ jobs:
with:
targets: aarch64-apple-ios

- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Install sccache
run: |
brew install sccache
sccache --version

- name: Cache sccache
uses: actions/cache@v4
with:
workspaces: "frontend/src-tauri -> target"
cache-on-failure: true
path: ~/Library/Caches/Mozilla.sccache
key: ${{ runner.os }}-sccache-testflight-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-sccache-testflight-
${{ runner.os }}-sccache-

- name: Install dependencies (macOS)
run: |
Expand Down Expand Up @@ -112,6 +120,12 @@ jobs:
echo "${{ secrets.APPLE_API_PRIVATE_KEY }}" | base64 --decode > ~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8
chmod 600 ~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8
echo "APPLE_API_KEY_PATH=~/.private_keys/AuthKey_${{ secrets.APPLE_API_KEY }}.p8" >> $GITHUB_ENV

- name: Configure sccache
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
echo "SCCACHE_CACHE_SIZE=2G" >> $GITHUB_ENV
sccache --show-stats
Comment thread
AnthonyRonning marked this conversation as resolved.
Outdated

- name: Build Tauri iOS App
working-directory: ./frontend
Expand Down
Loading