Skip to content

init build workflow

init build workflow #4

Workflow file for this run

name: build & test
env:
IMAGE_PREFIX: "ghcr.io/dnkpp/"
on:
push:
branches: [master, dev]
pull_request:
branches: [master, dev]
jobs:
build:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
container:
image: ghcr.io/dnkpp/${{ matrix.config.compiler_name }}:${{ matrix.config.compiler_version }}
strategy:
fail-fast: false
matrix:
build_mode: [Debug, Release]
config:
- {
name: "Linux Clang 18 C++23 ${{ matrix.build_mode }}",

Check failure on line 25 in .github/workflows/build.yml

View workflow run for this annotation

GitHub Actions / build & test

Invalid workflow file

The workflow is not valid. .github/workflows/build.yml (Line: 25, Col: 31): Unrecognized named-value: 'matrix'. Located at position 1 within expression: matrix.build_mode .github/workflows/build.yml (Line: 32, Col: 31): Unrecognized named-value: 'matrix'. Located at position 1 within expression: matrix.build_mode
os: ubuntu-latest,
compiler_name: clang,
compiler_version: 18,
cxx_standard: 23
}
- {
name: "Linux Clang 18 C++20 ${{ matrix.build_mode }}",
os: ubuntu-latest,
compiler_name: clang,
compiler_version: 18,
cxx_standard: 20
}
- {
name: "Linux Clang 17 C++23 ${{ matrix.build_mode }}",
os: ubuntu-latest,
compiler_name: clang,
compiler_version: 17,
cxx_standard: 23
}
- {
name: "Linux Clang 17 C++20 ${{ matrix.build_mode }}",
os: ubuntu-latest,
compiler_name: clang,
compiler_version: 17,
cxx_standard: 20
}
steps:
- uses: actions/checkout@v4
- name: Compile tests
run: |
cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_mode }} -B build -S .
cmake --build build -j4
- name: Run tests
env:
CTEST_OUTPUT_ON_FAILURE: 1
run: ctest --test-dir build/test -C ${{ matrix.build_mode }} -j4