Skip to content

Renames method for compile-time checking #9

Renames method for compile-time checking

Renames method for compile-time checking #9

Workflow file for this run

# .github/workflows/ci.yml
name: C/C++ CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
# use Bash everywhere (MSYS2 on Windows gives us bash, make, gcc, etc)
defaults:
run:
shell: bash
steps:
- uses: actions/checkout@v4
# Install compilers + make
- name: Install toolchain
if: runner.os == 'Linux'
run: |
sudo apt-get update
sudo apt-get install -y build-essential
- name: Install toolchain
if: runner.os == 'macOS'
run: |
brew update
brew install pkg-config
- name: Setup MSYS2 (Windows)
if: runner.os == 'Windows'
uses: msys2/setup-msys2@v2
with:
update: true
install: base-devel
# Build and test
- name: Build & Test
run: |
# pick up number of cores, fallback to 2
CORES=$(nproc 2>/dev/null || sysctl -n hw.ncpu 2>/dev/null || echo 2)
make -j"$CORES"