-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Simple command args parsing and execution -- -- This is a small wrapper over optparse-applicative which allows -- combining args parsers directly with IO commands, avoiding command -- type boilerplate. It supports subcommands and also provides a few -- option Mod functions. @package simple-cmd-args @version 0.1.0.1 -- | This library provides a thin layer on optparse-applicative argument -- and option parsing, using Parser (IO ()), applying commands -- directly to their argument parsing. -- -- A few option Mod functions are also provided. module SimpleCmdArgs -- | Parser executor (allows interspersed args and options) -- --
--   simpleCmdArgs (Just version) "summary" "program description" $ myCommand <$> myOptParser <*> myargsParser
--   
simpleCmdArgs :: Maybe Version -> String -> String -> Parser (IO ()) -> IO () -- | Parser executor without interspersing options and args -- --
--   simpleCmdArgs' Nothing "summary" "program description" $ myCommand <$> myOptParser <*> myargsParser
--   
simpleCmdArgs' :: Maybe Version -> String -> String -> Parser (IO ()) -> IO () -- |
--   Subcommand "command" "help description text" $ myCommand <$> optParser
--   
data Subcommand Subcommand :: String -> String -> Parser (IO ()) -> Subcommand -- | list of Subcommand that can be run by simpleCmdArgs subcommands :: [Subcommand] -> Parser (IO ()) -- | A string arg parser with a METAVAR for help strArg :: String -> Parser String -- | Mods for a switch. -- --
--   switchMods 'o' "option" "help description"
--   
switchMods :: HasName f => Char -> String -> String -> Mod f a -- | Mods for a mandatory option. -- --
--   optionMods 'o' "option" "METAVAR" "help description"
--   
optionMods :: (HasMetavar f, HasName f) => Char -> String -> String -> String -> Mod f a -- | Mods for an optional option: includes a default value. -- --
--   optionalMods 'o' "option" "METAVAR" "help description" default
--   
optionalMods :: (HasMetavar f, HasName f, HasValue f) => Char -> String -> String -> String -> a -> Mod f a