Skip to content

Commit 92c9d48

Browse files
committed
Some small stylistic adjustments
In the hope of improving clarity in the CI workflow.
1 parent 527f690 commit 92c9d48

File tree

1 file changed

+19
-18
lines changed

1 file changed

+19
-18
lines changed

.github/workflows/ci.yml

Lines changed: 19 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -213,9 +213,9 @@ jobs:
213213
- ubuntu-latest
214214
- ubuntu-24.04-arm
215215
include:
216-
- nextest-extra-args: ''
216+
- test-args: ''
217217
- os: windows-11-arm
218-
nextest-extra-args: '-- --skip fuzzed_timeout --skip performance --skip speed'
218+
test-args: '--skip fuzzed_timeout --skip performance --skip speed'
219219

220220
runs-on: ${{ matrix.os }}
221221

@@ -227,11 +227,11 @@ jobs:
227227
if (Get-Command rustup -ErrorAction SilentlyContinue) {
228228
Write-Output '::warning:: The runner has rustup. Consider removing this step.'
229229
} else {
230-
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL `
231-
--output rustup-init.exe `
232-
https://static.rust-lang.org/rustup/dist/aarch64-pc-windows-msvc/rustup-init.exe
233-
.\rustup-init.exe --default-toolchain none -y
234-
Remove-Item rustup-init.exe
230+
$file = 'rustup-init.exe'
231+
$url = "https://static.rust-lang.org/rustup/dist/aarch64-pc-windows-msvc/$file"
232+
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL --output $file $url
233+
& ".\$file" --default-toolchain none -y
234+
Remove-Item $file
235235
Add-Content -Value "$Env:USERPROFILE\.cargo\bin" -Path $Env:GITHUB_PATH
236236
}
237237
- uses: dtolnay/rust-toolchain@stable
@@ -245,7 +245,7 @@ jobs:
245245
- name: Test (nextest)
246246
env:
247247
GIX_TEST_CREATE_ARCHIVES_EVEN_ON_CI: '1'
248-
run: cargo nextest run --workspace --no-fail-fast ${{ matrix.nextest-extra-args }}
248+
run: cargo nextest run --workspace --no-fail-fast -- ${{ matrix.test-args }}
249249
- name: Check that tracked archives are up to date
250250
run: git diff --exit-code # If this fails, the fix is usually to commit a regenerated archive.
251251

@@ -256,18 +256,18 @@ jobs:
256256
- windows-latest
257257
- windows-11-arm
258258
include:
259-
- nextest-extra-args: ''
259+
- test-args: ''
260260
- os: windows-11-arm
261-
nextest-extra-args: '-- --skip fuzzed-timeout --skip performance --skip speed'
261+
test-args: '--skip fuzzed-timeout --skip performance --skip speed'
262262

263263
runs-on: ${{ matrix.os }}
264264

265265
steps:
266266
- name: Report version/build of Git in this runner image
267267
run: git version --build-options
268268
- name: Upgrade Git for Windows to latest stable release
269-
# TODO: Remove this and related steps once `windows-11-arm` ships a new enough Git version.
270-
# (The Windows 11 ARM runner still ships Git 2.48.*, so it remains affected by #1849.)
269+
# TODO(ci): Remove this and related steps once `windows-11-arm` ships a new enough Git.
270+
# The Windows 11 ARM runner still ships Git 2.48.*, so it remains affected by #1849.
271271
if: matrix.os == 'windows-11-arm'
272272
env:
273273
GH_TOKEN: ${{ github.token }}
@@ -304,11 +304,11 @@ jobs:
304304
if (Get-Command rustup -ErrorAction SilentlyContinue) {
305305
Write-Output '::warning:: The runner has rustup. Consider removing this step.'
306306
} else {
307-
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL `
308-
--output rustup-init.exe `
309-
https://static.rust-lang.org/rustup/dist/aarch64-pc-windows-msvc/rustup-init.exe
310-
.\rustup-init.exe --default-toolchain none -y
311-
Remove-Item rustup-init.exe
307+
$file = 'rustup-init.exe'
308+
$url = "https://static.rust-lang.org/rustup/dist/aarch64-pc-windows-msvc/$file"
309+
curl --proto '=https' --tlsv1.2 --retry 10 --retry-connrefused -fsSL --output $file $url
310+
& ".\$file" --default-toolchain none -y
311+
Remove-Item $file
312312
Add-Content -Value "$Env:USERPROFILE\.cargo\bin" -Path $Env:GITHUB_PATH
313313
}
314314
- uses: dtolnay/rust-toolchain@stable
@@ -320,7 +320,8 @@ jobs:
320320
id: nextest
321321
env:
322322
GIX_TEST_IGNORE_ARCHIVES: '1'
323-
run: cargo nextest --profile=with-xml run --workspace --no-fail-fast ${{ matrix.nextest-extra-args }}
323+
run: |
324+
cargo nextest --profile=with-xml run --workspace --no-fail-fast -- ${{ matrix.test-args }}
324325
continue-on-error: true
325326
- name: Check for errors
326327
run: |

0 commit comments

Comments
 (0)