diff options
Diffstat (limited to 'Git/Construct.hs')
-rw-r--r-- | Git/Construct.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Git/Construct.hs b/Git/Construct.hs index c013eb2..a5e825e 100644 --- a/Git/Construct.hs +++ b/Git/Construct.hs @@ -184,7 +184,10 @@ expandTilde :: FilePath -> IO FilePath #ifdef mingw32_HOST_OS expandTilde = return #else -expandTilde = expandt True +expandTilde p = expandt True p + -- If unable to expand a tilde, eg due to a user not existing, + -- use the path as given. + `catchNonAsync` (const (return p)) where expandt _ [] = return "" expandt _ ('/':cs) = do |