Skip to content

Commit e03e037

Browse files
Adding yml for GH Actions CI
1 parent 6018dd1 commit e03e037

File tree

1 file changed

+85
-0
lines changed

1 file changed

+85
-0
lines changed

.github/workflows/build_cmake.yml

Lines changed: 85 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# Note differences between Unix variants and Windows shell when invoking
2+
# multiple commands on one line - bash uses double ampersand, powershell
3+
# uses semi-colon
4+
#
5+
# Currently there is duplication, specially for the dependency management,
6+
# this should be refactored in the future
7+
#
8+
name: CMake Build Matrix
9+
10+
on:
11+
push:
12+
branches:
13+
- master
14+
- develop
15+
16+
jobs:
17+
18+
build-unixes:
19+
20+
runs-on: ${{ matrix.os }}
21+
strategy:
22+
matrix:
23+
os: [ubuntu-latest, macos-latest]
24+
25+
steps:
26+
- name: checkout
27+
uses: actions/checkout@v2
28+
with:
29+
path: main
30+
- name: checkout-utility-rack
31+
uses: actions/checkout@v2
32+
with:
33+
repository: utility-rack
34+
path: utility-rack
35+
- name: checkout-catch
36+
uses: actions/checkout@v2
37+
with:
38+
repository: catchorg/Catch2
39+
ref: master
40+
path: Catch2
41+
- name: checkout-asio
42+
uses: actions/checkout@v2
43+
with:
44+
repository: chriskohlhoff/asio
45+
ref: master
46+
path: asio
47+
- name: configure-cmake
48+
run: mkdir build && cd build && cmake ../main
49+
- name: build
50+
run: cd build && cmake --build .
51+
- name: unit-test
52+
run: cd build && ctest
53+
54+
build-windows:
55+
56+
runs-on: windows-latest
57+
58+
steps:
59+
- name: checkout
60+
uses: actions/checkout@v2
61+
with:
62+
path: main
63+
- name: checkout-utility-rack
64+
uses: actions/checkout@v2
65+
with:
66+
repository: utility-rack
67+
path: utility-rack
68+
- name: checkout-catch
69+
uses: actions/checkout@v2
70+
with:
71+
repository: catchorg/Catch2
72+
ref: master
73+
path: Catch2
74+
- name: checkout-asio
75+
uses: actions/checkout@v2
76+
with:
77+
repository: chriskohlhoff/asio
78+
ref: master
79+
path: asio
80+
- name: configure-cmake
81+
run: mkdir build; cd build; cmake ../main
82+
- name: build
83+
run: cd build; cmake --build .
84+
- name: unit-test
85+
run: cd build; ctest -C "Debug"

0 commit comments

Comments
 (0)