-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (24 loc) · 710 Bytes
/
ci.yml
File metadata and controls
31 lines (24 loc) · 710 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Configure
run: cmake -B build -DCMAKE_BUILD_TYPE=Release
- name: Build (Unix)
if: runner.os != 'Windows'
run: cmake --build build -j$(nproc 2>/dev/null || sysctl -n hw.ncpu)
- name: Build (Windows)
if: runner.os == 'Windows'
run: cmake --build build --config Release -j $env:NUMBER_OF_PROCESSORS
- name: Test
run: ctest --test-dir build --output-on-failure -C Release