Safe Haskell | None |
---|---|
Language | Haskell2010 |
This module provides a variant of usageInfo
.
Unlike the standard usageInfo
function, lists of long switches are broken
across multiple lines to economise on columns. For example,
-r --recursive add contents of subdirectories --not-recursive, --no-recursive don't add contents of subdirectories
- usageInfo :: String -> [DarcsOptDescr a] -> String
- formatOptions :: [DarcsOptDescr a] -> [String]
- getCommandHelp :: Maybe (DarcsCommand pf1) -> DarcsCommand pf2 -> Doc
- getCommandMiniHelp :: Maybe (DarcsCommand pf1) -> DarcsCommand pf2 -> String
- usage :: [CommandControl] -> Doc
- subusage :: DarcsCommand pf -> String
Documentation
usageInfo :: String -> [DarcsOptDescr a] -> String Source #
Variant of usageInfo
.
Return a string describing the usage of a command, derived from the header
(first argument) and the options described by the second argument.
Sequences of long switches are presented on separate lines.
formatOptions :: [DarcsOptDescr a] -> [String] Source #
getCommandHelp :: Maybe (DarcsCommand pf1) -> DarcsCommand pf2 -> Doc Source #
getCommandMiniHelp :: Maybe (DarcsCommand pf1) -> DarcsCommand pf2 -> String Source #
usage :: [CommandControl] -> Doc Source #
subusage :: DarcsCommand pf -> String Source #