summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJoey Hess2014-11-18 15:32:53 -0400
committerJoey Hess2014-11-18 15:32:53 -0400
commit2ca292a2b470bfbea621790e1fd6f2aa7350bac0 (patch)
treebf80df349b8dc4dc6c31fe004de73b3fdce7536a /src
parentced8d5959b542161976f84d6a645355bddbdc9ac (diff)
hook up handles
Diffstat (limited to 'src')
-rw-r--r--src/Propellor/CmdLine.hs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/Propellor/CmdLine.hs b/src/Propellor/CmdLine.hs
index df739e18..62fd68f6 100644
--- a/src/Propellor/CmdLine.hs
+++ b/src/Propellor/CmdLine.hs
@@ -13,6 +13,7 @@ import System.Posix.IO
import Data.Time.Clock.POSIX
import Control.Concurrent.Async
import qualified Data.ByteString as B
+import System.Process (std_in, std_out)
import Propellor
import Propellor.Protocol
@@ -212,7 +213,11 @@ spin hn hst = do
loop
Just NeedGitPush -> do
sendMarked toh gitPushMarker ""
- unlessM (boolSystem "git" [Param "upload-pack", Param "."]) $
+ let p = (proc "git" ["upload-pack", "."])
+ { std_in = UseHandle fromh
+ , std_out = UseHandle toh }
+ (Nothing, Nothing, Nothing, h) <- createProcess p
+ unlessM ((==) ExitSuccess <$> waitForProcess h) $
warningMessage "git send-pack failed"
-- no more protocol possible after
-- git push