summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBen Sima <ben@bsima.me>2021-01-19 12:19:53 -0500
committerBen Sima <ben@bsima.me>2021-01-22 07:19:33 -0500
commitefa278aa35816f2906e288ffef82d1100181b1e1 (patch)
treed892f36d206aba6a1889189e7e3c7ba76176f798
parent84e690b6f1c425b4a292f8dcb9be10a40fb466ae (diff)
Print help message with --help
-rw-r--r--Biz/Cli.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/Biz/Cli.hs b/Biz/Cli.hs
index 0f7b6d4..7ecd0c6 100644
--- a/Biz/Cli.hs
+++ b/Biz/Cli.hs
@@ -37,7 +37,10 @@ main Plan {..} =
>>= \args ->
if args `has` Docopt.command "test"
then runTests test
- else move args
+ else
+ if args `has` Docopt.longOption "help"
+ then Docopt.exitWithUsage help
+ else move args
runTests :: Tasty.TestTree -> IO ()
runTests tree = do