Open charlespierce opened 4 years ago
Alternatively, possibly look into creating the shims with hard links instead of symlinks, which in some quick testing appears to work. This will also probably require setting the Permission setting "WriteAttributes" on the installed shim.exe
in the WiX configuration.
I think I might be seeing this issue when using https://github.com/nushell/nushell on anything going through volta-shim.exe
as well, FWIW.
For reference, Chocolatey have a shim generator called shimgen, https://github.com/chocolatey/shimgen. It works well for me under any scenario: Git Bash, Powershell, cmd, UNCs.
For reference, Chocolatey have a shim generator called shimgen, https://github.com/chocolatey/shimgen. It works well for me under any scenario: Git Bash, Powershell, cmd, UNCs.
that shimgen is pretty slow and so many choco users complain about it, moreover, it's a closed source software.
There is also Scoop's Shim, https://github.com/ScoopInstaller/Shim. Very simple to use.
that shimgen is pretty slow and so many choco users complain about it, moreover, it's a closed source software.
Still about shimgen, there is https://github.com/turboBasic/shimPsy.
There is also Scoop's Shim, https://github.com/ScoopInstaller/Shim. Very simple to use.
Well, I'm one of the maintainers of Scoop and I know that. the initial version of Scoop's shim isn't robust. FYI, there are variants available, such as https://github.com/71/scoop-better-shimexe and https://github.com/kiennq/scoop-better-shimexe.
And I always want to see a modern, independent, well-designed implementation of Windows shimming tool.
There is also a Rust version (from Scoop) https://github.com/zoritle/rshim, which Rust Volta might like better :)
Symlinks in Windows come with a bunch of restrictions and edge-cases that make it hard for Volta to correctly determine the name of the tool that was called. A few of these include:
We could possibly solve these problems by creating a small executable that we could actually copy with a new name when creating a shim. This executable would be responsible for determining the command (possible because it's actually an on-disk executable) and then passing control to the full Volta shim while passing information about the tool (possibly using an Environment Variable).