Skip to content

CI

CI #17

Workflow file for this run

name: CI
on:
push:
pull_request:
branches:
- master
workflow_dispatch:
jobs:
build:
strategy:
fail-fast: false
matrix:
zig-version: ["0.14.1", "0.15.2", "master"]
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- zig-version: "0.15.2"
# -Dbuild-tests does not work when targeting Linux because the build
# system doesn't preserve linker input file order, which causes the
# linker to spew duplicate symbol errors.
os: macos-latest
check-format: true
build-options: "-Dbuild-tests -Dbuild-benchmarks"
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Setup Zig
uses: mlugg/setup-zig@v2
with:
version: ${{ matrix.zig-version }}
- if: ${{ matrix.check-format }}
name: Check Formatting
run: zig fmt --check --ast-check .
- name: Build
run: zig build ${{ matrix.build-options }} --summary all