Skip to content

Commit 37520d7

Browse files
committed
Add explicit import list to Options.BenchParser
Also, some reformatting
1 parent c2d89d4 commit 37520d7

File tree

1 file changed

+23
-14
lines changed

1 file changed

+23
-14
lines changed

src/Stack/Options/BenchParser.hs

Lines changed: 23 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,34 @@
11
{-# LANGUAGE NoImplicitPrelude #-}
22
{-# LANGUAGE OverloadedStrings #-}
33

4-
module Stack.Options.BenchParser where
4+
module Stack.Options.BenchParser
5+
( benchOptsParser
6+
) where
57

68
import Options.Applicative
7-
import Options.Applicative.Builder.Extra
9+
( Parser, flag', help, long, metavar, strOption )
10+
import Options.Applicative.Builder.Extra ( optionalFirst )
811
import Stack.Prelude
9-
import Stack.Options.Utils
10-
import Stack.Types.Config
12+
import Stack.Options.Utils ( hideMods )
13+
import Stack.Types.Config ( BenchmarkOptsMonoid (..) )
1114

1215
-- | Parser for bench arguments.
1316
-- FIXME hiding options
1417
benchOptsParser :: Bool -> Parser BenchmarkOptsMonoid
1518
benchOptsParser hide0 = BenchmarkOptsMonoid
16-
<$> optionalFirst (strOption (long "benchmark-arguments" <>
17-
long "ba" <>
18-
metavar "BENCH_ARGS" <>
19-
help ("Forward BENCH_ARGS to the benchmark suite. " <>
20-
"Supports templates from `cabal bench`") <>
21-
hide))
22-
<*> optionalFirst (flag' True (long "no-run-benchmarks" <>
23-
help "Disable running of benchmarks. (Benchmarks will still be built.)" <>
24-
hide))
25-
where hide = hideMods hide0
19+
<$> optionalFirst (strOption
20+
( long "benchmark-arguments"
21+
<> long "ba"
22+
<> metavar "BENCH_ARGS"
23+
<> help "Forward BENCH_ARGS to the benchmark suite. Supports templates \
24+
\from `cabal bench`"
25+
<> hide
26+
))
27+
<*> optionalFirst (flag' True
28+
( long "no-run-benchmarks"
29+
<> help "Disable running of benchmarks. (Benchmarks will still be \
30+
\built.)"
31+
<> hide
32+
))
33+
where
34+
hide = hideMods hide0

0 commit comments

Comments
 (0)