From 41a8908281000daf090a24ddc4b62ea7bc08dab0 Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Wed, 13 Dec 2023 13:17:18 +0100 Subject: [PATCH] build-and-deploy: use a better way to ensure that all packages are updated When `pacman -Syyu` (whose job is to update the packages in the Git for SDK) updates the MSYS2 runtime in a Bash step that uses said MSYS2 runtime, the step will stop and fail. A better way to run that command is via PowerShell, and an even better way is to use the same script that the `sync` automation of the `git-sdk-*` repositories already uses. So let's do that. Signed-off-by: Johannes Schindelin --- .github/workflows/build-and-deploy.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-and-deploy.yml b/.github/workflows/build-and-deploy.yml index 50bcefd0..d0fccc7b 100644 --- a/.github/workflows/build-and-deploy.yml +++ b/.github/workflows/build-and-deploy.yml @@ -98,6 +98,7 @@ jobs: - name: Download Git for Windows SDK uses: git-for-windows/setup-git-for-windows-sdk@v1 + id: setup-sdk with: flavor: ${{ env.PACKAGE_TO_BUILD == 'mingw-w64-git' && 'build-installers' || 'full' }} architecture: ${{ env.ARCHITECTURE || 'x86_64' }} @@ -122,9 +123,10 @@ jobs: shell: bash run: git clone --depth 1 --single-branch -b main https://github.com/git-for-windows/build-extra /usr/src/build-extra - - name: pacman -Syyu - shell: bash - run: pacman -Syyu --noconfirm + - name: update the SDK ("pacman -Syyu") + shell: powershell + run: | + & ("${{ steps.setup-sdk.outputs.result }}\update-via-pacman.ps1") - name: rebase `.dll` base addresses if: env.ARCHITECTURE == 'i686'