package mirage-runtime
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=ade8c410b2de3997c4a513f53f6c990dac6af508161e20df01b64fa7975ca5be
sha512=42fddf09be84c4251417145b88d4f63b41db1b29c9622b2b4e4508e31146f227a16875e670da96251208745f79a42f0b7d2bd8b44b883a705381b4c97a4255b8
doc/mirage-runtime.functoria/Functoria_runtime/index.html
Module Functoria_runtime
Source
Functoria runtime.
Arg
defines values that can be set by runtime command-line arguments. This module is the runtime companion of Functora.Runtime_arg
.
register t
registers the Cmdliner term k
as a runtime key and return a callback f
that evaluates to t
s' value passed on the command-line.
f
will raise Invalid_argument
if called before cmdliner's evaluation.
val with_argv :
?sections:string list ->
unit Cmdliner.Term.t list ->
string ->
string array ->
unit
with_argv ?sections keys name argv
evaluates the keys
terms on the command-line argv
. name
is the executable name. sections
is a list of sections to include in the man page - useful for enforcing a specific order of sections. On evaluation error the application calls exit(3)
with status 64
. If `Help
or `Version
were evaluated, exit(3)
is called with status 63
.
Exit Codes
argument_error
is the exit code used for argument parsing errors: 64.
help_version
is the exit code used when help/version is used: 63.