Created
December 15, 2019 00:39
-
-
Save ethomson/79c787cecee5c23f2c791500d6644583 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build with CMake and Ninja | |
on: [push] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: ['ubuntu-latest', 'windows-latest', 'macos-latest'] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: Install Dependencies (Linux) | |
run: sudo apt-get install ninja-build | |
if: matrix.os == 'ubuntu-latest' | |
- name: Install Dependencies (Windows) | |
run: choco install ninja | |
if: matrix.os == 'windows-latest' | |
- name: Install Dependencies (macOS) | |
run: brew install ninja | |
if: matrix.os == 'macos-latest' | |
- name: Get Sources | |
uses: actions/checkout@v1 | |
- name: Setup CMake | |
run: | | |
mkdir "${{ runner.workspace }}/build" | |
cd "${{ runner.workspace }}/build" | |
cmake $GITHUB_WORKSPACE -GNinja | |
shell: bash | |
- name: Build | |
run: cmake --build . | |
working-directory: ${{ runner.workspace }}/build | |
- name: Test | |
run: ctest -V | |
working-directory: ${{ runner.workspace }}/build |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment