Skip to content

Compile switcher properly #11

Compile switcher properly

Compile switcher properly #11

Workflow file for this run

# Runs on all other branches and ensures that the code builds successfully
name: Build
on:
push:
branches-ignore:
- master
jobs:
build-switcher:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v1
with:
node-version: "22.x"
- name: Install Switcher dependencies
run: npm ci
- name: Install Host dependencies
run: npm ci
working-directory: ./host
- name: Build Switcher
run: sh ./scripts/compile_switcher.sh
build-host:
needs: build-switcher
permissions:
contents: write
strategy:
fail-fast: false
matrix:
include:
- platform: "macos-latest"
args: "--target aarch64-apple-darwin"
- platform: "macos-latest"
args: "--target x86_64-apple-darwin"
- platform: "ubuntu-22.04"
args: ""
- platform: "windows-latest"
args: ""
runs-on: ${{ matrix.platform }}
steps:
- name: install Rust stable
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.platform == 'macos-latest' && 'aarch64-apple-darwin,x86_64-apple-darwin' || '' }}
- name: Install Dependencies (Ubuntu only)
if: matrix.platform == 'ubuntu-22.04'
run: |
sudo apt-get update
sudo apt-get install -y libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf
- uses: tauri-apps/tauri-action@v0
with:
projectPath: ./host
args: ${{ matrix.args }}