Skip to content

Commit 49c5024

Browse files
authored
Fix runner label windows-2022 (#18)
The windows-latest runners no longer ships with the Visual Studio 17 2022 generator, which breaks the Windows CI build. Pin the runner to windows-2022 to restore compatibility. The winget package manager is not available on windows-2022 — download and install mosquitto via run instead.
1 parent e2c722f commit 49c5024

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

.github/workflows/ci-downstream.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ jobs:
2424
},
2525
{
2626
"match-jobs": ["windows-*"],
27-
"winget-install": ["EclipseFoundation.Mosquitto"]
27+
"run": "$ErrorActionPreference='Stop'; Invoke-WebRequest -Uri 'https://mosquitto.org/files/binary/win64/mosquitto-2.0.18-install-windows-x64.exe' -OutFile mosq.exe; Start-Process -FilePath ./mosq.exe -ArgumentList '/S' -Wait; Start-Service mosquitto"
2828
},
2929
{
3030
"match-jobs": ["macos-*"],

.github/workflows/ci.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,13 @@ jobs:
1919
- os: ubuntu-latest
2020
generator: Ninja
2121
build_type: Debug
22-
- os: windows-latest
22+
- os: windows-2022
2323
generator: "Visual Studio 17 2022"
2424
build_type: Debug
2525
- os: ubuntu-latest
2626
generator: Ninja
2727
build_type: Release
28-
- os: windows-latest
28+
- os: windows-2022
2929
generator: "Visual Studio 17 2022"
3030
build_type: Release
3131

@@ -69,13 +69,13 @@ jobs:
6969
- os: ubuntu-latest
7070
generator: Ninja
7171
build_type: Debug
72-
- os: windows-latest
72+
- os: windows-2022
7373
generator: "Visual Studio 17 2022"
7474
build_type: Debug
7575
- os: ubuntu-latest
7676
generator: Ninja
7777
build_type: Release
78-
- os: windows-latest
78+
- os: windows-2022
7979
generator: "Visual Studio 17 2022"
8080
build_type: Release
8181

@@ -122,7 +122,7 @@ jobs:
122122
cmake --install build/output --config "${{ matrix.build_type }}"
123123
124124
- name: Add DLL path (Windows only)
125-
if: matrix.os == 'windows-latest'
125+
if: matrix.os == 'windows-2022'
126126
run: echo "${{ env.INSTALL_PREFIX }}/lib" >> $env:GITHUB_PATH
127127

128128
- name: Configure project with CMake

0 commit comments

Comments
 (0)