From c753cd282d1e150e2d3f7534a3e25004d6c2cf5f Mon Sep 17 00:00:00 2001 From: Jordan Borean Date: Tue, 30 Jan 2024 09:17:04 +1000 Subject: [PATCH] Add support for PowerShell 7.4 in GHA Fixes compatibility with PowerShell 7.3 on Windows through GitHub Actions when one of the options for cibuildwheel is empty. --- action.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/action.yml b/action.yml index ab07817dc..b71ede7a0 100644 --- a/action.yml +++ b/action.yml @@ -46,7 +46,13 @@ runs: if: runner.os != 'Windows' # Windows needs powershell to interact nicely with Meson + # $PSNativeCommandArgumentPassing was introduced in pwsh 7.3 and the + # legacy behaviour is needed for backwards compatibility with how this + # was called in the past. - run: > + if ($PSNativeCommandArgumentPassing) { + $PSNativeCommandArgumentPassing = 'Legacy' + }; pipx run --python "${{ steps.python.outputs.python-path }}" --spec "${{ github.action_path }}"