Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to PowerShell Core 7.4.0 in Linux build VMs #3902

Closed
limdor opened this issue Dec 31, 2023 · 1 comment
Closed

Update to PowerShell Core 7.4.0 in Linux build VMs #3902

limdor opened this issue Dec 31, 2023 · 1 comment
Assignees

Comments

@limdor
Copy link

limdor commented Dec 31, 2023

Linux build VMs currently have PowerShell Core 7.3.7. It would be good to update to 7.4.0 for the following reason.

PowerShell 7.3 introduced a experimental feature called PSNativeCommandErrorActionPreference that allows to make a script fail if a command returns a none 0 exit code without having to check for the return code.
https://learn.microsoft.com/en-us/powershell/scripting/learn/experimental-features?view=powershell-7.4#psnativecommanderroractionpreference
In 7.4 this feature is not experimental anymore.

It is not easy (I did not manage yet) to enable an experimental feature in Appveyor because it requires a shell restart. Updating to 7.4 would allow to use this feature without having to enable it.

Windows build VMs for Visual Sutdio 2019 and 2022 already have PowerShell 7.4.0, this would bring both to the same version without having to have different scripts for the different images.
macOS build VMs has currently version 7.3.0, you might want to consider if possible to also update PowerShell Core to 7.4.0. I'm not sure why there is currently 3 different versions all different for Linux, Windows, and macOS.

@OwenMcDonnell
Copy link

https://www.appveyor.com/updates/2024/03/08/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants