ci: set git fetch depth, swap rust cache #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build iOS App | |
| on: | |
| push: | |
| branches: ['main', 'master'] | |
| paths: | |
| - 'src-tauri/**/*.rs' | |
| - 'src-tauri/**/*.toml' | |
| - 'src-tauri/dist/**' | |
| - 'src-tauri/tauri.conf.json' | |
| - 'src-tauri/gen/apple/**/*.swift' | |
| - 'src-tauri/gen/apple/**/*.plist' | |
| - 'fastlane/**' | |
| - 'package.json' | |
| - 'package-lock.json' | |
| - '.github/workflows/build-ios-app.yml' | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: macos-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| - name: Setup Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: '3.4' | |
| bundler-cache: true | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '24' | |
| cache: 'npm' | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: aarch64-apple-ios | |
| - name: Cache Rust | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: src-tauri -> target | |
| cache-targets: true | |
| cache-on-failure: true | |
| - name: Install npm dependencies | |
| run: npm ci | |
| - name: Initialize iOS project | |
| run: cd src-tauri && npx tauri ios init | |
| - name: Build and upload to TestFlight | |
| run: bundle exec fastlane beta | |
| env: | |
| AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | |
| AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | |
| AWS_ENDPOINT_URL: ${{ secrets.AWS_ENDPOINT_URL }} | |
| MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }} | |
| APP_STORE_CONNECT_API_KEY_KEY_ID: ${{ secrets.APP_STORE_CONNECT_API_KEY_KEY_ID }} | |
| APP_STORE_CONNECT_API_KEY_ISSUER_ID: ${{ secrets.APP_STORE_CONNECT_API_KEY_ISSUER_ID }} | |
| APP_STORE_CONNECT_API_KEY_KEY: ${{ secrets.APP_STORE_CONNECT_API_KEY_KEY }} |