Capture command output and print it prettier
Getty Ritter
6 years ago
27 | 27 | runCommand root src = do |
28 | 28 | forM_ (sourceCommands src) $ \ln -> do |
29 | 29 | let dir = root </> sourceDir src |
30 |
cDebug (" $ " % string % " (in |
|
30 | cDebug (" $ " % string % " (in '" % string % "')") ln dir | |
31 | 31 | (outH, inH) <- Sys.createPipe |
32 | 32 | let process = (Sys.shell ln) { Sys.cwd = Just (root </> sourceDir src) |
33 | 33 | , Sys.std_out = Sys.UseHandle inH |