fix(ci): run all release jobs on titan host runner #12
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: Tauri Cross-Platform Build | ||
|
Check failure on line 1 in .github/workflows/tauri-build-cross.yml
|
||
| on: | ||
| workflow_dispatch: | ||
| inputs: | ||
| platforms: | ||
| description: 'Platforms to build' | ||
| required: true | ||
| default: 'all' | ||
| type: choice | ||
| options: | ||
| - all | ||
| - windows | ||
| - macos | ||
| jobs: | ||
| build-tauri: | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| include: | ||
| - platform: windows-latest | ||
| target: x86_64-pc-windows-msvc | ||
| - platform: macos-latest | ||
| target: aarch64-apple-darwin | ||
| if: >- | ||
| inputs.platforms == 'all' || | ||
| (inputs.platforms == 'windows' && matrix.platform == 'windows-latest') || | ||
| (inputs.platforms == 'macos' && matrix.platform == 'macos-latest') | ||
| runs-on: ${{ matrix.platform }} | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Setup Node.js | ||
| uses: actions/setup-node@v4 | ||
| with: | ||
| node-version: '20' | ||
| cache: 'npm' | ||
| cache-dependency-path: ui/package-lock.json | ||
| - name: Install Rust stable | ||
| uses: dtolnay/rust-toolchain@stable | ||
| with: | ||
| targets: ${{ matrix.target }} | ||
| - name: Rust cache | ||
| uses: swatinem/rust-cache@v2 | ||
| with: | ||
| workspaces: ui/src-tauri -> target | ||
| - name: Install frontend dependencies | ||
| working-directory: ui | ||
| run: npm ci | ||
| - name: Build Tauri app | ||
| uses: tauri-apps/tauri-action@v0 | ||
| env: | ||
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
| CARGO_BUILD_JOBS: "8" | ||
| with: | ||
| projectPath: ui | ||
| tauriScript: npm run tauri | ||
| - name: Upload artifacts | ||
| uses: actions/upload-artifact@v3 | ||
| with: | ||
| name: tauri-${{ matrix.platform }} | ||
| path: | | ||
| ui/src-tauri/target/release/bundle/**/*.dmg | ||
| ui/src-tauri/target/release/bundle/**/*.exe | ||
| ui/src-tauri/target/release/bundle/**/*.msi | ||
| if-no-files-found: warn | ||