Fix: modularize CI workflows
All checks were successful
Deploy Website / deploy (push) Has been skipped

This commit is contained in:
2026-03-01 23:18:08 +01:00
parent eeefb7d54d
commit 88cb43a760
8 changed files with 576 additions and 420 deletions

View File

@@ -4,71 +4,25 @@ on:
push:
tags: ['v*']
env:
CARGO_TERM_COLOR: always
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
check:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
- os: macos-14
target: aarch64-apple-darwin
- os: windows-latest
target: x86_64-pc-windows-msvc
linux:
uses: ./.github/workflows/build-linux.yml
with:
run-tests: true
run-clippy: true
runs-on: ${{ matrix.os }}
timeout-minutes: 20
macos:
uses: ./.github/workflows/build-macos.yml
with:
run-tests: true
run-clippy: true
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
components: clippy
- name: Cache Rust dependencies
uses: Swatinem/rust-cache@v2
with:
key: ${{ matrix.target }}
- name: Install dependencies (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y build-essential cmake pkg-config libasound2-dev libclang-dev libjack-dev \
libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxkbcommon-dev libssl-dev libgl1-mesa-dev \
libx11-dev libx11-xcb-dev libxcursor-dev libxrandr-dev libxi-dev libwayland-dev
- name: Install dependencies (macOS)
if: runner.os == 'macOS'
run: brew list cmake &>/dev/null || brew install cmake
- name: Install dependencies (Windows)
if: runner.os == 'Windows'
run: |
choco install cmake --installargs 'ADD_CMAKE_TO_PATH=System'
echo "C:\Program Files\CMake\bin" >> $env:GITHUB_PATH
- name: Build
run: cargo build --release --target ${{ matrix.target }}
- name: Build desktop
run: cargo build --release --features desktop --bin cagire-desktop --target ${{ matrix.target }}
- name: Test
run: cargo test --target ${{ matrix.target }}
- name: Clippy
run: cargo clippy --target ${{ matrix.target }} -- -D warnings
windows:
uses: ./.github/workflows/build-windows.yml
with:
run-tests: true
run-clippy: true