summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2011-07-02 19:22:11 -0400
committerGravatar Joey Hess <joey@kitenet.net>2011-07-02 19:22:11 -0400
commit591e293f43f7e4450b570f0e6e95c1a33cd50f44 (patch)
tree5ee1eed4a19dab8313c3c7209fef34951204cd3a
parentf626512b07f3675f184101c4c945861381862339 (diff)
simplify git cat-file startup
-rw-r--r--Branch.hs8
1 files changed, 3 insertions, 5 deletions
diff --git a/Branch.hs b/Branch.hs
index d9cbe61a7..c0c96611b 100644
--- a/Branch.hs
+++ b/Branch.hs
@@ -237,11 +237,9 @@ catFile file = do
where
startup state = do
g <- Annex.gitRepo
- let cmd = Git.gitCommandLine g
- [Param "cat-file", Param "--batch"]
- let gitcmd = join " " ("git" : toCommand cmd)
- (_, from, to) <- liftIO $ hPipeBoth "sh"
- ["-c", "exec " ++ gitcmd ++ " 2>/dev/null"]
+ (_, from, to) <- liftIO $ hPipeBoth "git" $
+ toCommand $ Git.gitCommandLine g
+ [Param "cat-file", Param "--batch"]
setState state { catFileHandles = Just (from, to) }
ask (from, to)
ask (from, to) = liftIO $ do