From bf9e458fd74a9d187be6929c212e46b341b05c8c Mon Sep 17 00:00:00 2001 From: Daniel Gröber Date: Wed, 30 Jan 2019 20:59:12 +0100 Subject: Add log-level to verbosity conditional --- src/CabalHelper/Compiletime/Program/CabalInstall.hs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/CabalHelper/Compiletime/Program/CabalInstall.hs') diff --git a/src/CabalHelper/Compiletime/Program/CabalInstall.hs b/src/CabalHelper/Compiletime/Program/CabalInstall.hs index 3f87215..f989a02 100644 --- a/src/CabalHelper/Compiletime/Program/CabalInstall.hs +++ b/src/CabalHelper/Compiletime/Program/CabalInstall.hs @@ -1,4 +1,4 @@ -{-# LANGUAGE DataKinds #-} +{-# LANGUAGE DataKinds, MultiWayIf #-} -- cabal-helper: Simple interface to Cabal's configuration state -- Copyright (C) 2018 Daniel Gröber @@ -118,9 +118,9 @@ callCabalInstall then ["--no-require-sandbox"] else [] , [ "install", srcdir ] - , if ?verbose - then ["-v"] - else [] + , if | ?verbose 3 -> ["-v2"] + | ?verbose 4 -> ["-v3"] + | otherwise -> [] , [ "--only-dependencies" ] ] @@ -216,9 +216,9 @@ installCabalLibV2 _ghcVer (CabalVersion cabalVer) (PackageEnvFile env_file) = do , "--lib" , "Cabal-"++showVersion cabalVer ] - , if ?verbose - then ["-v"] - else [] + , if | ?verbose 3 -> ["-v2"] + | ?verbose 4 -> ["-v3"] + | otherwise -> [] ] tmp <- getTemporaryDirectory callProcessStderr (Just tmp) (cabalProgram ?progs) cabal_opts -- cgit v1.2.3