From 1871b0a0b81262c40ffb661c27447fd501ec7e05 Mon Sep 17 00:00:00 2001 From: Eldred Habert Date: Thu, 21 May 2026 21:25:29 +0200 Subject: [PATCH] Use Windows git for checkout's post-job cleanup, not Cygwin's git (#1953) This fixes an error from using Cygwin's git in checkout's post-job cleanup --- .github/workflows/testing.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index a1f2eb3c..7eb45adb 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -332,6 +332,10 @@ jobs: run: shell: C:\cygwin\bin\env.exe CYGWIN_NOWINPATH=1 CHERE_INVOKING=1 C:\cygwin\bin\bash.exe -o igncr '{0}' steps: + - name: Save Windows git location for the PATH + shell: pwsh + run: | # The `cygwin/cygwin-install-action` step will override the PATH with Cygwin's binaries + "ORIGINAL_GIT_DIR=$(Split-Path (Get-Command git).Source)" >> $env:GITHUB_ENV - name: Checkout repo uses: actions/checkout@v6 - name: Setup Cygwin @@ -352,6 +356,10 @@ jobs: - name: Run tests run: | test/run-tests.sh --only-internal + - name: Use Windows git location in the PATH + shell: pwsh + run: | # Prevents the `actions/checkout` post-job cleanup from using Cygwin's git binary + "$env:ORIGINAL_GIT_DIR" >> $env:GITHUB_PATH freebsd: runs-on: ubuntu-latest