| 1 | name: Deploy Frontend Splitfire Desktop |
| 2 | on: |
| 3 | push: |
| 4 | branches: |
| 5 | - splitfire/release/splitfire-desktop |
| 6 | workflow_dispatch: |
| 7 | jobs: |
| 8 | publish: |
| 9 | permissions: |
| 10 | contents: write |
| 11 | strategy: |
| 12 | fail-fast: false |
| 13 | matrix: |
| 14 | include: |
| 15 | - platform: "macos-latest" # for Arm based macs (M1 and above). |
| 16 | args: "--target aarch64-apple-darwin" |
| 17 | runs-on: ${{ matrix.platform }} |
| 18 | steps: |
| 19 | - uses: actions/checkout@v4 |
| 20 | |
| 21 | - name: Setup Node |
| 22 | uses: actions/setup-node@v4 |
| 23 | with: |
| 24 | node-version-file: frontend/splitfire-desktop/.nvmrc |
| 25 | |
| 26 | - name: Setup Rust toolchain |
| 27 | uses: dtolnay/rust-toolchain@stable |
| 28 | with: |
| 29 | toolchain: 1.77.0 |
| 30 | # Those targets are only used on macos runners so it's in an `if` to slightly speed up windows and linux builds. |
| 31 | targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }} |
| 32 | - name: Build app |
| 33 | run: | |
| 34 | cd frontend/splitfire-desktop |
| 35 | npm install |
| 36 | npm run tauri-build |