startExternal externaltype = do
errrelayer <- mkStderrRelayer
liftIO $ do
- (Just hin, Just hout, Just herr, pid) <- createProcess $
- (proc cmd [])
- { std_in = CreatePipe
- , std_out = CreatePipe
- , std_err = CreatePipe
- }
+ (Just hin, Just hout, Just herr, pid) <-
+ createProcess p `catchIO` runerr
fileEncoding hin
fileEncoding hout
fileEncoding herr
}
where
cmd = externalRemoteProgram externaltype
+ p = (proc cmd [])
+ { std_in = CreatePipe
+ , std_out = CreatePipe
+ , std_err = CreatePipe
+ }
+
+ runerr _ = error ("Cannot run " ++ cmd ++ " -- Make sure it's in your PATH and is executable.")
checkearlytermination Nothing = noop
checkearlytermination (Just exitcode) = ifM (inPath cmd)
--- /dev/null
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 6"""
+ date="2015-11-18T16:22:51Z"
+ content="""
+@rob.syme I think that error message is pretty clear: git-annex-remote-ipfs
+is not present in your PATH or perhaps is not executable.
+
+(Still, the error message could be improved a bit, doing that now.)
+"""]]