TASEmulators / BizHawk

BizHawk is a multi-system emulator written in C#. BizHawk provides nice features for casual gamers such as full screen, and joypad support in addition to full rerecording and debugging tools for all system cores.
http://tasvideos.org/BizHawk.html
Other
2.2k stars 385 forks source link

Port shell scripts to PowerShell, merging w/ Batch scripts where possible #3013

Open YoshiRulz opened 2 years ago

YoshiRulz commented 2 years ago

I've come around to the idea of PowerShell on Linux after getting a working Nix expression into the repo. After all, if I make Nix a requirement for Linux devs (as I plan to), what harm is another dependency?

And of course, PowerShell is available OOTB on Win10.

If an OS-specific call needs to be made (considering all of the .NET BCL is available, unlikely) it may be easier to use a polyglot hack in a separate script than to conditionally invoke the relevant programs. I'm not familiar enough with PowerShell to say.

notes:


It might be worth extracting shell scripts from the GitLab CI config and porting them as well. For the most part they just call the scripts in /Dist. (See also my notes on dotnet publish.)

If MSBuild can run PowerShell scripts (I haven't checked), we can replace everything in /Build and the target in BizHawk.Version.csproj with PowerShell too. Replaced w/ Source Generator.

see also #2073

dennisrijsdijk commented 2 years ago

Note about powershell, some antiviruses (on windows at least) will block any powershell execution, without clear errors about it.

YoshiRulz commented 2 years ago

This only applies to developers, who I'm assuming are clever enough to get around that.

CasualPokePlayer commented 5 months ago

And of course, PowerShell is available OOTB on Win10.

PowerShell is not, Windows PowerShell is. https://learn.microsoft.com/en-us/powershell/scripting/what-is-windows-powershell

Windows PowerShell and PowerShell are two separate products.

Windows PowerShell is the version of PowerShell that ships in Windows. This version of PowerShell uses the full .NET Framework, which only runs on Windows. The latest version is Windows PowerShell 5.1. Microsoft is no longer updating Windows PowerShell with new features. Support for Windows PowerShell is tied to the version of Windows you are using.

PowerShell is built on the new versions of .NET instead of the .NET Framework and runs on Windows, Linux, and macOS. Support for PowerShell is based on the version of .NET that it was built on. For more information about the support lifecycle for PowerShell, see the PowerShell support lifecycle documentation.

Notable difference is PowerShell is pwsh.exe, while Windows PowerShell is powershell.exe.