summaryrefslogtreecommitdiff
path: root/Git
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2015-01-06 17:33:29 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2015-01-06 17:33:29 -0400
commit834e27580383e4fa74f72e73448f8c5fc3c8e541 (patch)
tree091a44cd54c5b1029bc0cac1d9c8346830c44bc7 /Git
parentbc620991aa586d6758e5ef997342899edc87bc4a (diff)
git-hash-object needs absolute files (git bug)
A relative path to a file makes it fail. I am pretty sure this is a git bug; workaround it.
Diffstat (limited to 'Git')
-rw-r--r--Git/HashObject.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Git/HashObject.hs b/Git/HashObject.hs
index 97e1befe6..8cd35167d 100644
--- a/Git/HashObject.hs
+++ b/Git/HashObject.hs
@@ -32,7 +32,7 @@ hashObjectStop = CoProcess.stop
hashFile :: HashObjectHandle -> FilePath -> IO Sha
hashFile h file = CoProcess.query h send receive
where
- send to = hPutStrLn to file
+ send to = hPutStrLn to =<< absPath file
receive from = getSha "hash-object" $ hGetLine from
{- Injects a blob into git. Unfortunately, the current git-hash-object