fix #22
Workflow file for this run
This file contains 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 | |
on: | |
push: | |
workflow_call: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
jobs: | |
build: | |
strategy: | |
fail-fast: false | |
matrix: | |
settings: | |
# MacOS (Intel) | |
- platform: macos-latest | |
target: x86_64-apple-darwin | |
# MacOS (Apple Silicon) | |
- platform: macos-latest | |
target: aarch64-apple-darwin | |
# 64-bit Linux | |
- platform: ubuntu-22.04 | |
target: x86_64-unknown-linux-gnu | |
# 64-bit Windows | |
- platform: windows-latest | |
target: x86_64-pc-windows-msvc | |
# 32-bit Windows | |
- platform: windows-latest | |
target: i686-pc-windows-msvc | |
runs-on: ${{ matrix.settings.platform }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v2 | |
with: | |
version: 8.14.1 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
cache: pnpm | |
# - run: | | |
# rustup toolchain install stable --profile minimal --target ${{ matrix.settings.target }} | |
# rustup target add ${{ matrix.settings.target }} | |
# rustup default stable | |
- uses: dtolnay/rust-toolchain@stable | |
- name: install dependencies | |
run: | | |
rustup target add ${{ matrix.target }} | |
rustup toolchain install --force-non-host ${{ matrix.toolchain }} | |
- uses: swatinem/rust-cache@988c164c3d0e93c4dbab36aaf5bbeb77425b2894 | |
with: | |
workspaces: packages/desktop | |
- name: Install dependencies (Ubuntu) | |
if: matrix.settings.platform == 'ubuntu-22.04' | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y libgtk-3-dev libwebkit2gtk-4.1-dev libappindicator3-dev librsvg2-dev patchelf | |
- run: pnpm i | |
- run: | | |
pnpm build --filter zebar --filter @zebar/client | |
pnpm build --filter @zebar/desktop -- -- --target ${{ matrix.settings.target }} | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: bundle-${{ matrix.settings.target }} | |
path: | | |
packages/desktop/target/release/bundle/**/*.AppImage | |
packages/desktop/target/release/bundle/**/*.dmg | |
packages/desktop/target/release/bundle/**/*.deb | |
packages/desktop/target/release/bundle/**/*.msi |