File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CMake Build and Test
2+
3+ on :
4+ push :
5+ branches : [ "main" ]
6+ pull_request :
7+ branches : [ "main" ]
8+
9+ env :
10+ BUILD_TYPE : Release
11+
12+ jobs :
13+ build :
14+ runs-on : ubuntu-latest
15+
16+ steps :
17+ - name : Checkout repository
18+ uses : actions/checkout@v4
19+
20+ - name : Install dependencies
21+ run : sudo apt-get update && sudo apt-get install -y cmake g++
22+
23+ - name : Configure CMake
24+ run : cmake -S . -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}}
25+
26+ - name : Build all targets
27+ run : cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}}
28+
29+ - name : Run all CTest tests
30+ working-directory : ${{github.workspace}}/build
31+ run : ctest --output-on-failure -C ${{env.BUILD_TYPE}}
You can’t perform that action at this time.
0 commit comments