| ||||||||||||||||||
| ||||||||||||||||||
| ||||||||||||||||||
| Description | ||||||||||||||||||
| Explanation: Data types and parser for the standard command-line setup. | ||||||||||||||||||
| Synopsis | ||||||||||||||||||
| Command interface | ||||||||||||||||||
| data CommandUI flags | ||||||||||||||||||
| ||||||||||||||||||
| commandShowOptions :: CommandUI flags -> flags -> [String] | ||||||||||||||||||
| Show flags in the standard long option command line format | ||||||||||||||||||
| Constructing commands | ||||||||||||||||||
| data ShowOrParseArgs | ||||||||||||||||||
| ||||||||||||||||||
| makeCommand | ||||||||||||||||||
| ||||||||||||||||||
| data Option a | ||||||||||||||||||
| option :: [Char] -> [String] -> String -> c -> d -> (c -> d -> ArgDescr a) -> Option a | ||||||||||||||||||
| data ArgDescr a | ||||||||||||||||||
| noArg :: Monoid a => a -> (a -> Bool) -> (b -> a) -> (a -> b -> b) -> ArgDescr b | ||||||||||||||||||
| reqArg :: Monoid a => String -> (String -> a) -> (a -> [String]) -> (b -> a) -> (a -> b -> b) -> ArgDescr b | ||||||||||||||||||
| optArg :: Monoid a => String -> (Maybe String -> a) -> (a -> [Maybe String]) -> (b -> a) -> (a -> b -> b) -> ArgDescr b | ||||||||||||||||||
| Associating actions with commands | ||||||||||||||||||
| data Command action | ||||||||||||||||||
| commandAddAction :: CommandUI flags -> (flags -> [String] -> action) -> Command action | ||||||||||||||||||
| Running commands | ||||||||||||||||||
| data CommandParse flags | ||||||||||||||||||
| ||||||||||||||||||
| commandsRun :: CommandUI a -> [Command action] -> [String] -> CommandParse (a, CommandParse action) | ||||||||||||||||||
| Produced by Haddock version 0.9 | ||||||||||||||||||