Windows: Look for .exe extension when searching for a command in path.
This commit is contained in:
parent
74ad3072e4
commit
86b845ff8d
2 changed files with 7 additions and 1 deletions
|
@ -181,7 +181,12 @@ searchPath command
|
||||||
| otherwise = getSearchPath >>= getM indir
|
| otherwise = getSearchPath >>= getM indir
|
||||||
where
|
where
|
||||||
indir d = check $ d </> command
|
indir d = check $ d </> command
|
||||||
check f = ifM (doesFileExist f) ( return (Just f), return Nothing )
|
check f = firstM doesFileExist
|
||||||
|
#ifdef __WINDOWS__
|
||||||
|
[f, f ++ ".exe"]
|
||||||
|
#else
|
||||||
|
[f]
|
||||||
|
#endif
|
||||||
|
|
||||||
{- Checks if a filename is a unix dotfile. All files inside dotdirs
|
{- Checks if a filename is a unix dotfile. All files inside dotdirs
|
||||||
- count as dotfiles. -}
|
- count as dotfiles. -}
|
||||||
|
|
1
debian/changelog
vendored
1
debian/changelog
vendored
|
@ -17,6 +17,7 @@ git-annex (4.20130628) UNRELEASED; urgency=low
|
||||||
branch works.
|
branch works.
|
||||||
* addurl --pathdepth: Fix failure when the pathdepth specified is deeper
|
* addurl --pathdepth: Fix failure when the pathdepth specified is deeper
|
||||||
than the urls's path.
|
than the urls's path.
|
||||||
|
* Windows: Look for .exe extension when searching for a command in path.
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Tue, 02 Jul 2013 15:40:55 -0400
|
-- Joey Hess <joeyh@debian.org> Tue, 02 Jul 2013 15:40:55 -0400
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue