mirror of
https://github.com/commercialhaskell/stackage.git
synced 2026-02-20 18:25:48 +01:00
Don't buffer build.log (fixes #75)
This commit is contained in:
parent
d63bab8194
commit
5c5406358f
@ -12,8 +12,9 @@ import Stackage.InstallInfo
|
|||||||
import Stackage.Types
|
import Stackage.Types
|
||||||
import Stackage.Util
|
import Stackage.Util
|
||||||
import System.Exit (ExitCode (ExitSuccess), exitWith)
|
import System.Exit (ExitCode (ExitSuccess), exitWith)
|
||||||
import System.IO (IOMode (WriteMode), hPutStrLn,
|
import System.IO (BufferMode (NoBuffering),
|
||||||
withBinaryFile)
|
IOMode (WriteMode), hPutStrLn,
|
||||||
|
hSetBuffering, withBinaryFile)
|
||||||
import System.Process (rawSystem, runProcess,
|
import System.Process (rawSystem, runProcess,
|
||||||
waitForProcess)
|
waitForProcess)
|
||||||
|
|
||||||
@ -48,6 +49,8 @@ build settings' bp = do
|
|||||||
let installBuildTool tool = do
|
let installBuildTool tool = do
|
||||||
putStrLn $ "Installing build tool: " ++ tool
|
putStrLn $ "Installing build tool: " ++ tool
|
||||||
ec <- withBinaryFile "build-tools.log" WriteMode $ \handle -> do
|
ec <- withBinaryFile "build-tools.log" WriteMode $ \handle -> do
|
||||||
|
hSetBuffering handle NoBuffering
|
||||||
|
|
||||||
let args = addCabalArgs settings BSBuild
|
let args = addCabalArgs settings BSBuild
|
||||||
$ "install"
|
$ "install"
|
||||||
: ("--cabal-lib-version=" ++ libVersion)
|
: ("--cabal-lib-version=" ++ libVersion)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user