Module Kwapp.Help

module Help: sig .. end
Help and Usage Messages

val getoptstring : Kwapp.interface -> string
getoptstring interface: return a string representing the options part of the command line.
Raises Failure if applied to a nameless switch
interface : the interface
val helpstring : Kwapp.interface -> string
helpstring interface: generate multi-line help message summarizing command-line options.
interface : the interface
val usage1 : ?sub:string -> Kwapp.interface -> string
usage1 ?sub interface: generate a one-line usage message string, without the traditional leading "Usage: ".

Contains the name of the executable, then an optional subcommand name, then a summary of the options, then finally a summary of the argv parameters.
Raises Failure if applied to a nameless switch

sub : a subcommand name to insert
interface : the interface
val usagestring : ?sort:bool ->
?actions:(Kwapp.dispatchmode * 'a) list ->
?versiondata:(string * string) list ->
?sub:string -> Kwapp.interface -> string
usagestring ?actions ?sub ?versiondata interface: generate a complete multi-line usage message string.

If actions is provided, the usage string will also summarize the subcommands.

If versiondata is provided, a one-line summary of the version data will be included.
Raises Failure if applied to a nameless switch

actions : actions list
versiondata : the version data
sub : a subcommand name to insert
val usage : ?actions:(Kwapp.dispatchmode * 'a) list ->
?sub:string ->
?versiondata:(string * string) list ->
?status:int -> ?chan:Pervasives.out_channel -> Kwapp.interface -> 'b
usage ?actions ?sub ?status ?chan interface: print a complete multi-line usage message string on chan and exit with status.

If actions is provided, the usage string will also summarize the subcommands.

If versiondata is provided, a one-line summary of the version data will be included.
Raises Failure if applied to a nameless switch

actions : actions list
sub : a subcommand name to insert
versiondata : the version data
status : the exit status (default: 1)
chan : the channel on which to print (default: standard error)
interface : the interface
val action : ?actions:(Kwapp.dispatchmode * 'c) list ->
?sub:string -> ?versiondata:(string * string) list -> ('a, 'b) Kwapp.action
action ?actions ?sub ?versiondata interface: an action suitable for Kwapp.dispatch that generates a complete help message on stdout and terminates the program with exit status 0.

If actions is provided, the usage string will also summarize the subcommands.

If versiondata is provided, a one-line summary of the version data will be included.
Raises Failure if applied to a nameless switch

actions : actions list
sub : a subcommand name to insert
versiondata : the version data
interface : the interface
val helpaction : ?actions:(Kwapp.dispatchmode * 'a) list ->
?sub:string -> ?versiondata:(string * string) list -> ('b, 'c) Kwapp.action
Deprecated.Use Kwapp.Help.action instead.
helpaction: deprecated name of Kwapp.Help.action