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
-- | Get a full path to an executable by looking at the @PATH@ environement
-- variable. Windows normally looks in additional places besides the
-- @PATH@: this does not duplicate that behavior.
whichEith :: FilePath -> Sh (Either String FilePath)
whichEith originalFp = whichFull
#if defined(mingw32_HOST_OS)
$ case extension originalFp of
Nothing -> originalFp <.> "exe"
Just _ -> originalFp
#else
originalFp
#endif
I am guessing this is an attempt to work somewhat like how Windows usually looks for executables. I do not see any non-breaking way to change how whichEith works, but here are two ideas:
Do nothing to the file path, regardless of OS. This requires Shelly users to append .exe themselves.
First try and find the file without the .exe suffix. If that fails, try and find the file with the .exe suffix. Maybe this causes the wrong executable to be used.
I would happily send in a PR for either of these but because it is a breaking change either way I assume it wants to be discussed.
A snippet from the source code:
I am guessing this is an attempt to work somewhat like how Windows usually looks for executables. I do not see any non-breaking way to change how
whichEith
works, but here are two ideas:.exe
themselves..exe
suffix. If that fails, try and find the file with the.exe
suffix. Maybe this causes the wrong executable to be used.I would happily send in a PR for either of these but because it is a breaking change either way I assume it wants to be discussed.
Related to #112
The text was updated successfully, but these errors were encountered: