diff options
author | Teddy Wing | 2017-08-20 18:17:54 +0200 |
---|---|---|
committer | Teddy Wing | 2017-08-20 18:17:54 +0200 |
commit | 5792fb1fc1439994a4877761820d8d034b66110d (patch) | |
tree | 37209d27856028dc320acf85103bc601ce1d281a /src/CliOptions.hs | |
parent | b8d535020feeea4233306c2063f19c25f383384f (diff) | |
download | sorbot-5792fb1fc1439994a4877761820d8d034b66110d.tar.bz2 |
CliOptions(parseOptions): Return options
Make the parsed options accessible to the rest of the program.
Diffstat (limited to 'src/CliOptions.hs')
-rw-r--r-- | src/CliOptions.hs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/CliOptions.hs b/src/CliOptions.hs index b848e2b..60f05ad 100644 --- a/src/CliOptions.hs +++ b/src/CliOptions.hs @@ -1,5 +1,7 @@ module CliOptions - ( parseOptions + ( Options(..) + + , parseOptions ) where import Data.Semigroup ((<>)) @@ -24,10 +26,9 @@ options = Options <> value "en" <> help "Set the language Sorbot will speak in (en | fr)" ) -parseOptions :: IO () +parseOptions :: IO Options parseOptions = do execParser opts - return () where opts = info (options <**> helper) ( fullDesc |