optparse-applicative-simple-1.1.0.2: Simple command line interface arguments parser

OptparseApplicative.Simple.Parser

Synopsis

# Documentation

type Parser = Parser Source #

Specification of a command line arguments parser and help generator.

Has instances of Functor, Applicative and Alternative, which you can use for composition.

Arguments

 :: Text Long name -> Maybe Char Possible short name -> Maybe Text Possible description -> Maybe (a, Text) Possible default value with its text representation to display in the generated help -> Parser a Attoparsec parser of the value. The "attoparsec-data" package provides such parsers for a lot of standard types -> Parser a

Definition of a single argument.

Arguments

 :: Show a => Text Long name -> Maybe Char Possible short name -> Maybe Text Possible description -> Maybe a Possible default value -> Parser a Attoparsec parser of the value. The "attoparsec-data" package provides such parsers for a lot of standard types -> Parser a

lenientArgument :: LenientParser a => Text -> Maybe Char -> Maybe Text -> Maybe (a, Text) -> Parser a Source #

Same as argument, only provided with a default parser.

showableLenientArgument :: (LenientParser a, Show a) => Text -> Maybe Char -> Maybe Text -> Maybe a -> Parser a Source #

Same as showableArgument, only provided with a default parser.