From c8936038dc5013e56b6a0973c55f0321886ee9f8 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 8 Jul 2013 14:51:43 -0400 Subject: [PATCH] reorg --- Utility/Process.hs | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) diff --git a/Utility/Process.hs b/Utility/Process.hs index a98d04df56..3a8677fa3d 100644 --- a/Utility/Process.hs +++ b/Utility/Process.hs @@ -296,16 +296,6 @@ showCmd = go . cmdspec go (ShellCommand s) = s go (RawCommand c ps) = c ++ " " ++ show ps -{- Wrappers for System.Process functions that do debug logging. - - - - More could be added, but these are the only ones I usually need. - -} - -createProcess :: CreateProcess -> IO (Maybe Handle, Maybe Handle, Maybe Handle, ProcessHandle) -createProcess p = do - debugProcess p - System.Process.createProcess p - {- Starts an interactive process. Unlike runInteractiveProcess in - System.Process, stderr is inherited. -} startInteractiveProcess @@ -322,3 +312,9 @@ startInteractiveProcess cmd args environ = do } (Just from, Just to, _, pid) <- createProcess p return (pid, to, from) + +{- Wrapper around System.Process function that does debug logging. -} +createProcess :: CreateProcess -> IO (Maybe Handle, Maybe Handle, Maybe Handle, ProcessHandle) +createProcess p = do + debugProcess p + System.Process.createProcess p