You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: Have gix_path::env::shell() look more carefully
It now prefers the `(git root)/bin/sh.exe` shim, falling back to
the `(git root)/usr/bin/sh.exe` non-shim to support the Git for
Windows SDK which doesn't have the shim.
The reason to prefer the shim is that it sets environment
variables, including prepending `bin` directories that provide
tools one would expect to have when using it. Without this, common
POSIX commands may be unavailable, or different and incompatible
implementations of them may be found. In particular, if they are
found in a different MSYS2 installation whose `msys-2.0.dll` is of
a different version or otherwise a different build, then calling
them directly may produce strange behavior. See:
- https://cygwin.com/faq.html#faq.using.multiple-copies
- GitoxideLabs#1862 (comment)
Overall this makes things more robust than either preferring the
non-shim or just doing a path search for `sh` as was done before
that. But it exacerbates GitoxideLabs#1868 (as described there), so if the Git
for Windows `sh.exe` shim continues to work as it currently does,
then further improvements may be called for here.
0 commit comments