-
Notifications
You must be signed in to change notification settings - Fork 82
51 lines (37 loc) · 1.19 KB
/
CI-windows.yml
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
# Some convenient links:
# - https://github.com/actions/virtual-environments/blob/master/images/win/Windows2019-Readme.md
#
name: CI-windows
on: [push,pull_request]
defaults:
run:
shell: cmd
jobs:
build:
strategy:
matrix:
os: [windows-2019, windows-2022]
config: [Release, Debug]
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Setup msbuild.exe
uses: microsoft/setup-msbuild@v2
- name: Run cmake
if: matrix.os == 'windows-2019'
run: |
cmake -G "Visual Studio 16 2019" -A x64 . || exit /b !errorlevel!
- name: Run cmake
if: matrix.os == 'windows-2022'
run: |
cmake -G "Visual Studio 17 2022" -A x64 . || exit /b !errorlevel!
- name: Build
run: |
msbuild -m simplecpp.sln /p:Configuration=${{ matrix.config }} /p:Platform=x64 || exit /b !errorlevel!
- name: Test
run: |
.\${{ matrix.config }}\testrunner.exe || exit /b !errorlevel!
- name: Selfcheck
run: |
.\${{ matrix.config }}\simplecpp.exe simplecpp.cpp -e || exit /b !errorlevel!