-
Notifications
You must be signed in to change notification settings - Fork 2
56 lines (47 loc) · 1.74 KB
/
main.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: CppLintCombineCI
on: [push]
jobs:
build:
name: ${{ matrix.config.name }}
runs-on: ${{ matrix.config.os }}
strategy:
fail-fast: false
matrix:
config:
- {
name: "Windows Latest MSVC",
os: windows-latest
}
- {
name: "Ubuntu 20.04",
os: ubuntu-20.04
}
steps:
- uses: actions/checkout@v2
- name: PrepareRepo
shell: bash
run: git submodule update --init --recursive yaml-cpp && git tag 1.0.0
- name: InstallBoostOnWindows
if: startsWith(matrix.config.os, 'windows')
run: |
$url = "https://github.com/actions/boost-versions/releases/download/1.73.0-20200608.5/boost-1.73.0-win32-msvc14.2-x86_64.tar.gz"
(New-Object System.Net.WebClient).DownloadFile($url, "$($env:TEMP)\boost.tar.gz")
7z.exe x "$($env:TEMP)\boost.tar.gz" -o"$($env:TEMP)" -y | Out-Null
$tarPath = Get-ChildItem -Path "$($env:TEMP)" -Filter "boost-*.tar" | Select-Object -First 1
7z.exe x $tarPath -o"$($env:TEMP)/boost" -y | Out-Null
Push-Location -Path "$($env:TEMP)\boost"
Invoke-Expression .\setup.ps1
- name: ConfigureWindows
shell: bash
if: startsWith(matrix.config.os, 'windows')
run: cmake -S . -B . -A Win32 -T host=x86 -DBOOST_ROOT=${RUNNER_TOOL_CACHE}/boost/1.73.0/x86_64
- name: ConfigureLinux
shell: bash
if: startsWith(matrix.config.os, 'ubuntu')
run: sudo apt-get install -y libboost-all-dev ninja-build && cmake -G "Ninja Multi-Config" -S . -B .
- name: Build
shell: bash
run: cmake --build . --config ReleaseChecked
- name: Tests
shell: bash
run: ctest -C ReleaseChecked --verbose