feat: add --shell option for powershell/pwsh shell-executor jobs
Closes #1739
Shell-executor jobs always ran through Git Bash. Add --shell bash|powershell|pwsh (also GCL_SHELL or SHELL= in .gitlab-ci-local-env) so those jobs can run in Windows PowerShell or PowerShell Core, with job variables passed into the process.
Container jobs still use bash inside the image.
Tested on Windows with PowerShell 5.1 and pwsh 7.6. The new tests run only on Windows, so Linux CI will skip them.
Summary by cubic
Shell-executor jobs can now run in Windows PowerShell or PowerShell Core instead of Git Bash via a new --shell option, also settable with GCL_SHELL in the environment or SHELL= in .gitlab-ci-local-env. Job variables take precedence over the host environment, and interactive jobs keep reading from stdin. Container jobs still use bash inside the image. Closes #1739.
- Failing native commands stop the job with the correct exit code; status checks are inserted after complete statements (parsed by PowerShell) so if/else, try/catch, pipelines, and here-strings are not broken.
- Windows PowerShell 5.x script files include a UTF-8 BOM so they parse reliably.
- PowerShell tests run only on Windows; Linux CI skips them.