37
37
- target : x86_64-pc-windows-msvc
38
38
run_tests : YES
39
39
- target : x86_64-pc-windows-gnu
40
- mingw : https://ci-mirrors.rust-lang.org/rustc/x86_64-6.3.0-release-posix-seh-rt_v5-rev2.7z
41
40
mingwdir : mingw64
42
41
steps :
43
42
- uses : actions/checkout@v4
@@ -57,17 +56,16 @@ jobs:
57
56
New-Item "${env:USERPROFILE}\.cargo\git" -ItemType Directory -Force
58
57
shell : powershell
59
58
- name : Install mingw
59
+ uses : msys2/setup-msys2@v2
60
+ if : matrix.mingwdir != ''
61
+ with :
62
+ msystem : ${{ matrix.mingwdir }}
63
+ - name : Add mingw tools to path
64
+ shell : powershell
65
+ if : matrix.mingwdir != ''
60
66
run : |
61
- # We retrieve mingw from the Rust CI buckets
62
- # Disable the download progress bar which can cause perf issues
63
- $ProgressPreference = "SilentlyContinue"
64
- Invoke-WebRequest ${{ matrix.mingw }} -OutFile mingw.7z
65
- 7z x -y mingw.7z -oC:\msys64 | Out-Null
66
- del mingw.7z
67
67
echo "C:\msys64\usr\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
68
68
echo "C:\msys64\${{ matrix.mingwdir }}\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
69
- shell : powershell
70
- if : matrix.mingw != ''
71
69
- name : Set PATH
72
70
run : |
73
71
echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
@@ -123,7 +121,7 @@ jobs:
123
121
cargo check --all --all-targets --features test
124
122
git ls-files -- '*.rs' | xargs touch
125
123
- name : Run cargo clippy
126
- if : matrix.mode != 'release' && matrix.mingw == ''
124
+ if : matrix.mode != 'release' && matrix.mingwdir == ''
127
125
env :
128
126
TARGET : ${{ matrix.target }}
129
127
run : |
@@ -179,7 +177,6 @@ jobs:
179
177
- target : x86_64-pc-windows-msvc
180
178
run_tests : YES
181
179
- target : x86_64-pc-windows-gnu
182
- mingw : https://ci-mirrors.rust-lang.org/rustc/x86_64-6.3.0-release-posix-seh-rt_v5-rev2.7z
183
180
mingwdir : mingw64
184
181
steps :
185
182
- uses : actions/checkout@v4
@@ -199,17 +196,16 @@ jobs:
199
196
New-Item "${env:USERPROFILE}\.cargo\git" -ItemType Directory -Force
200
197
shell : powershell
201
198
- name : Install mingw
199
+ uses : msys2/setup-msys2@v2
200
+ if : matrix.mingwdir != ''
201
+ with :
202
+ msystem : ${{ matrix.mingwdir }}
203
+ - name : Add mingw tools to path
204
+ shell : powershell
205
+ if : matrix.mingwdir != ''
202
206
run : |
203
- # We retrieve mingw from the Rust CI buckets
204
- # Disable the download progress bar which can cause perf issues
205
- $ProgressPreference = "SilentlyContinue"
206
- Invoke-WebRequest ${{ matrix.mingw }} -OutFile mingw.7z
207
- 7z x -y mingw.7z -oC:\msys64 | Out-Null
208
- del mingw.7z
209
207
echo "C:\msys64\usr\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
210
208
echo "C:\msys64\${{ matrix.mingwdir }}\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
211
- shell : powershell
212
- if : matrix.mingw != ''
213
209
- name : Set PATH
214
210
run : |
215
211
echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
@@ -265,7 +261,7 @@ jobs:
265
261
cargo check --all --all-targets --features test
266
262
git ls-files -- '*.rs' | xargs touch
267
263
- name : Run cargo clippy
268
- if : matrix.mode != 'release' && matrix.mingw == ''
264
+ if : matrix.mode != 'release' && matrix.mingwdir == ''
269
265
env :
270
266
TARGET : ${{ matrix.target }}
271
267
run : |
@@ -323,11 +319,9 @@ jobs:
323
319
- target : x86_64-pc-windows-msvc
324
320
run_tests : YES
325
321
- target : x86_64-pc-windows-gnu
326
- mingw : https://ci-mirrors.rust-lang.org/rustc/x86_64-6.3.0-release-posix-seh-rt_v5-rev2.7z
327
322
mingwdir : mingw64
328
323
- target : i686-pc-windows-gnu # skip-pr skip-master
329
324
mingwdir : mingw32 # skip-pr skip-master
330
- mingw : https://ci-mirrors.rust-lang.org/rustc/i686-6.3.0-release-posix-dwarf-rt_v5-rev2.7z # skip-pr skip-master
331
325
steps :
332
326
- uses : actions/checkout@v4
333
327
# v2 defaults to a shallow checkout, but we need at least to the previous tag
@@ -346,17 +340,16 @@ jobs:
346
340
New-Item "${env:USERPROFILE}\.cargo\git" -ItemType Directory -Force
347
341
shell : powershell
348
342
- name : Install mingw
343
+ uses : msys2/setup-msys2@v2
344
+ if : matrix.mingwdir != ''
345
+ with :
346
+ msystem : ${{ matrix.mingwdir }}
347
+ - name : Add mingw tools to path
348
+ shell : powershell
349
+ if : matrix.mingwdir != ''
349
350
run : |
350
- # We retrieve mingw from the Rust CI buckets
351
- # Disable the download progress bar which can cause perf issues
352
- $ProgressPreference = "SilentlyContinue"
353
- Invoke-WebRequest ${{ matrix.mingw }} -OutFile mingw.7z
354
- 7z x -y mingw.7z -oC:\msys64 | Out-Null
355
- del mingw.7z
356
351
echo "C:\msys64\usr\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
357
352
echo "C:\msys64\${{ matrix.mingwdir }}\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
358
- shell : powershell
359
- if : matrix.mingw != ''
360
353
- name : Set PATH
361
354
run : |
362
355
echo "%USERPROFILE%\.cargo\bin" | Out-File -Append -FilePath $env:GITHUB_PATH -Encoding utf8
@@ -412,7 +405,7 @@ jobs:
412
405
cargo check --all --all-targets --features test
413
406
git ls-files -- '*.rs' | xargs touch
414
407
- name : Run cargo clippy
415
- if : matrix.mode != 'release' && matrix.mingw == ''
408
+ if : matrix.mode != 'release' && matrix.mingwdir == ''
416
409
env :
417
410
TARGET : ${{ matrix.target }}
418
411
run : |
0 commit comments