Skip to content

Commit e0cc964

Browse files
committed
Minor modernization for CI
1 parent 4ecf0f0 commit e0cc964

File tree

4 files changed

+106
-5
lines changed

4 files changed

+106
-5
lines changed

.github/workflows/ci-linux.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ permissions:
1515

1616
jobs:
1717
build:
18-
runs-on: ubuntu-22.04
18+
runs-on: ubuntu-latest
1919
strategy:
2020
fail-fast: false
2121
matrix:
@@ -112,4 +112,4 @@ jobs:
112112
run: cmake --build --preset="${{ matrix.buildPreset }}"
113113

114114
- name: Test
115-
run: ctest --preset="${{ matrix.testPreset }}" --output-on-failure --verbose --schedule-random -F
115+
run: ctest --preset="${{ matrix.testPreset }}" --output-on-failure --schedule-random -F

.github/workflows/ci-macos-m1.yml

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
name: ci-macos
2+
3+
on:
4+
push:
5+
tags-ignore:
6+
- v*.*
7+
branches:
8+
- '*'
9+
pull_request:
10+
branches:
11+
- '*'
12+
13+
permissions:
14+
contents: read
15+
16+
jobs:
17+
build:
18+
runs-on: macos-latest
19+
strategy:
20+
fail-fast: false
21+
matrix:
22+
include:
23+
- name: clang-debug-cxx17
24+
configurePreset: ninja-clang-debug
25+
buildPreset: build-ninja-clang-debug
26+
testPreset: test-ninja-clang-debug
27+
cxx_version: 17
28+
29+
- name: clang-debug-cxx20
30+
configurePreset: ninja-clang-debug
31+
buildPreset: build-ninja-clang-debug
32+
testPreset: test-ninja-clang-debug
33+
cxx_version: 20
34+
35+
- name: clang-release-cxx17
36+
configurePreset: ninja-clang-release
37+
buildPreset: build-ninja-clang-release
38+
testPreset: test-ninja-clang-release
39+
cxx_version: 17
40+
41+
- name: clang-release-cxx20
42+
configurePreset: ninja-clang-release
43+
buildPreset: build-ninja-clang-release
44+
testPreset: test-ninja-clang-release
45+
cxx_version: 20
46+
47+
- name: gcc-debug-cxx17
48+
configurePreset: ninja-gcc-debug
49+
buildPreset: build-ninja-gcc-debug
50+
testPreset: test-ninja-gcc-debug
51+
cxx_version: 17
52+
53+
- name: gcc-debug-cxx20
54+
configurePreset: ninja-gcc-debug
55+
buildPreset: build-ninja-gcc-debug
56+
testPreset: test-ninja-gcc-debug
57+
cxx_version: 20
58+
59+
- name: gcc-release-cxx17
60+
configurePreset: ninja-gcc-release
61+
buildPreset: build-ninja-gcc-release
62+
testPreset: test-ninja-gcc-release
63+
cxx_version: 17
64+
65+
- name: gcc-release-cxx20
66+
configurePreset: ninja-gcc-release
67+
buildPreset: build-ninja-gcc-release
68+
testPreset: test-ninja-gcc-release
69+
cxx_version: 20
70+
71+
steps:
72+
- name: Harden Runner
73+
uses: step-security/[email protected]
74+
with:
75+
egress-policy: audit
76+
77+
- uses: actions/checkout@v4
78+
79+
- name: Cache build
80+
uses: actions/cache@v4
81+
with:
82+
path: |
83+
./**/CMakeFiles
84+
./**/CMakeCache.txt
85+
./**/out
86+
key: ${{ runner.os }}-${{ matrix.name }}
87+
88+
- name: Install Homebrew
89+
run: /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
90+
91+
- name: Install Ninja
92+
run: brew install ninja
93+
94+
- name: Configure
95+
run: cmake --preset="${{ matrix.configurePreset }}" -DCMAKE_CXX_STANDARD="${{ matrix.cxx_version }}"
96+
97+
- name: Build
98+
run: cmake --build --preset="${{ matrix.buildPreset }}"
99+
100+
- name: Test
101+
run: ctest --preset="${{ matrix.testPreset }}" --output-on-failure --schedule-random -F

.github/workflows/ci-macos.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ permissions:
1515

1616
jobs:
1717
build:
18-
runs-on: macos-14
18+
runs-on: macos-13
1919
strategy:
2020
fail-fast: false
2121
matrix:
@@ -98,4 +98,4 @@ jobs:
9898
run: cmake --build --preset="${{ matrix.buildPreset }}"
9999

100100
- name: Test
101-
run: ctest --preset="${{ matrix.testPreset }}" --output-on-failure --verbose --schedule-random -F
101+
run: ctest --preset="${{ matrix.testPreset }}" --output-on-failure --schedule-random -F

.github/workflows/ci-windows.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ permissions:
1515

1616
jobs:
1717
build:
18-
runs-on: windows-2022
18+
runs-on: windows-latest
1919
strategy:
2020
fail-fast: false
2121
matrix:

0 commit comments

Comments
 (0)