Open CraigHutchinson opened 3 years ago
How do we get Ardunio IDE bugs chased up, I would be willing to look into this one but the code is foreign to me atm so would need some initial guidance. It is apparent that the PWSH is installed as a symbolic-link and the IDE most likely is not following the links.
Issue
Powershell can be installed on Windows or MacOS and a script is used from a custom
platform.txt
but thepwsh
fails to be found even though it can be ran from anycmd
windows or terminalReproducer
Winows Powershell 7 can be obtained from the store here https://www.microsoft.com/store/productId/9MZ1SNWT0N5D Then in Platform.txt add:
recipe.hooks.sketch.prebuild.01.pattern=pwsh
Diagnostics
On windows
pwsh
is installed toC:\Program Files\WindowsApps\Microsoft.PowerShell_7.1.3.0_x64__8wekyb3d8bbwe
which is not part of 'path' however there is some sort of symlink (alias?) that is used MacOs similar occurrence but a symlink exists to/usr/local/microsoft/powershell/7
but Ardunio IDE doens't seem to follow links.Workaround
Pretty hacky and destined to fail after an update but on Windows adding the
C:\Program Files\WindowsApps\Microsoft.PowerShell_7.1.3.0_x64__8wekyb3d8bbwe
to PATH environment is a workaround, we tried to repeat it on MacOS but modifying PATH was not as easy.Conclusion
The Arduino IDE is not following/supporting Symlinks in some manner and/or launching in some 'custom' manner that does not reproduce what a
cmd
orterminal
prompt can launch.