KeSp_controller/.github/workflows/release.yml
Mae PUGIN efd1e8ebf4 fix: Remove macOS Intel target, fix CI
macOS x86_64 not needed (all modern Macs are ARM).
3 targets: Linux x86_64, Windows x86_64, macOS ARM64.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-07 16:39:52 +02:00

66 lines
1.8 KiB
YAML

name: Release
on:
push:
tags: ['v*']
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
target: x86_64-unknown-linux-gnu
name: KeSp_controller-linux-x86_64
- os: windows-latest
target: x86_64-pc-windows-msvc
name: KeSp_controller-windows-x86_64.exe
- os: macos-latest
target: aarch64-apple-darwin
name: KeSp_controller-macos-arm64
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
- name: Install system deps (Linux)
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y libudev-dev libfontconfig1-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxkbcommon-dev libssl-dev libdbus-1-dev
- name: Build
run: cargo build --release --target ${{ matrix.target }}
- name: Rename binary
shell: bash
run: |
src="target/${{ matrix.target }}/release/KeSp_controller"
[ -f "${src}.exe" ] && src="${src}.exe"
cp "$src" "${{ matrix.name }}"
- uses: actions/upload-artifact@v4
with:
name: ${{ matrix.name }}
path: ${{ matrix.name }}
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/download-artifact@v4
- uses: softprops/action-gh-release@v2
with:
files: |
KeSp_controller-linux-x86_64/KeSp_controller-linux-x86_64
KeSp_controller-windows-x86_64.exe/KeSp_controller-windows-x86_64.exe
KeSp_controller-macos-arm64/KeSp_controller-macos-arm64