CMake #261
This file contains 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
# workflows to do unit-tests | |
name: CMake | |
on: | |
schedule: | |
# Nightly build at 3:42 A.M. | |
- cron: "42 3 */1 * *" | |
push: | |
branches: | |
- main | |
# Release branches | |
- "[0-9]+.[0-9]+.X" | |
pull_request: | |
branches: | |
- main | |
- "[0-9]+.[0-9]+.X" | |
release: | |
types: [published] | |
# Manual run | |
#workflow_dispatch: | |
env: | |
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.) | |
BUILD_TYPE: Release | |
jobs: | |
build-cxx: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Configure | |
run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} | |
- name: Compile | |
# Build your program with the given configuration | |
run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} -j | |
#- name: Test | |
# working-directory: ${{github.workspace}}/build | |
# Execute tests defined by the CMake configuration. | |
# See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail | |
#run: ctest -C ${{env.BUILD_TYPE}} |