diff options
author | Ben Sima <ben@bsima.me> | 2021-02-05 21:56:20 -0500 |
---|---|---|
committer | Ben Sima <ben@bsima.me> | 2021-02-05 21:56:20 -0500 |
commit | 753cdfe8c18b470da4a4807815d0aaade53f1d16 (patch) | |
tree | 1194557e0e0ab2e825c2786bf4bcccc33e86da27 /Biz/Cli.hs | |
parent | 1c75a8ee4c9914c7d482b38195b813b12ef4f834 (diff) |
Add 'tidy' to Plan
This is supposed to be how to cleanup the database and any other local files.
Should only be used before/after test, so maybe I can find a way to enforce this
constraint somehow in the code.
Diffstat (limited to 'Biz/Cli.hs')
-rw-r--r-- | Biz/Cli.hs | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -24,13 +24,14 @@ import qualified System.Environment as Environment import qualified Test.Tasty as Tasty import qualified Test.Tasty.Runners as Tasty -data Plan = Plan +data Plan cfg = Plan { help :: Docopt.Docopt, move :: Docopt.Arguments -> IO (), - test :: Tasty.TestTree + test :: Tasty.TestTree, + tidy :: cfg -> IO () } -main :: Plan -> IO () +main :: Plan cfg -> IO () main Plan {..} = Environment.getArgs +> Docopt.parseArgsOrExit help |