Skip to content

Commit 76ac75b

Browse files
committed
cpp-packaging.yml: explicitly add patch.exe from Chocolatey to the front of the PATH
1 parent fa8a18d commit 76ac75b

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/cpp-packaging.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -427,14 +427,20 @@ jobs:
427427
428428
# Install the latest version of GNU patch to avoid using the problematic patch.exe
429429
# from Strawberry Perl which sometimes crashes (Googlers see b/236958574).
430-
- name: Install patch.exe (Windows)
430+
- name: Install patch.exe via Chocolatey (Windows)
431431
if: startsWith(matrix.os, 'windows')
432432
uses: nick-invision/retry@v2
433433
with:
434434
timeout_minutes: 4
435435
max_attempts: 3
436436
shell: bash
437437
command: choco install patch --yes --nocolor
438+
439+
- name: Add patch.exe from Chocolatey to the front of the PATH (Windows)
440+
if: startsWith(matrix.os, 'windows')
441+
shell: bash
442+
run: |
443+
echo 'C:\\ProgramData\\chocolatey\\lib\\patch\\tools\\bin' >> $GITHUB_PATH
438444
439445
# Run the build in the host OS default shell since Windows can't handle long path names in bash.
440446
- name: Build desktop SDK

0 commit comments

Comments
 (0)