@@ -27,7 +27,7 @@ import Distribution.PackageDescription
27
27
import Distribution.Simple.Utils
28
28
import Distribution.Version
29
29
30
- import Distribution.Client.Setup (CommonSetupFlags ( .. ), ConfigFlags ( .. ), GlobalFlags (.. ))
30
+ import Distribution.Client.Setup (GlobalFlags (.. ))
31
31
32
32
-- Project orchestration imports
33
33
@@ -40,7 +40,6 @@ import Distribution.Client.ProjectOrchestration
40
40
import Distribution.Client.ScriptUtils
41
41
import Distribution.Client.TargetProblem
42
42
import Distribution.Simple.Command
43
- import Distribution.Simple.Flag
44
43
import Distribution.Types.Component
45
44
import Distribution.Verbosity
46
45
@@ -84,8 +83,7 @@ genBoundsCommand =
84
83
-- | The action for the @gen-bounds@ command when used in a project context.
85
84
genBoundsAction :: NixStyleFlags GenBoundsFlags -> [String ] -> GlobalFlags -> IO ()
86
85
genBoundsAction flags targetStrings globalFlags =
87
- withContextAndSelectors RejectNoTargets Nothing flags targetStrings globalFlags OtherCommand $ \ targetCtx ctx targetSelectors -> do
88
- let verbosity = fromFlagOrDefault normal (setupVerbosity $ configCommonFlags $ configFlags flags)
86
+ withContextAndSelectors verbosity RejectNoTargets Nothing flags targetStrings globalFlags OtherCommand $ \ targetCtx ctx targetSelectors -> do
89
87
90
88
baseCtx <- case targetCtx of
91
89
ProjectContext -> return ctx
@@ -155,6 +153,8 @@ genBoundsAction flags targetStrings globalFlags =
155
153
notice verbosity boundsNeededMsg
156
154
mapM_ (renderBoundsResult verbosity) boundsActions
157
155
else notice verbosity " All bounds up-to-date"
156
+ where
157
+ verbosity = cfgVerbosity normal flags
158
158
159
159
data GenBoundsResult = GenBoundsResult PackageIdentifier ComponentTarget (Maybe [PackageIdentifier ])
160
160
0 commit comments