mirror of
https://github.com/c-cube/linol.git
synced 2025-12-05 19:00:34 -05:00
46 lines
1.6 KiB
Text
46 lines
1.6 KiB
Text
{0 Cmdliner {%html: <span class="version">v2.1.0</span>%}}
|
|
|
|
Cmdliner provides a simple and compositional mechanism
|
|
to convert command line arguments to OCaml values and pass them to
|
|
your functions.
|
|
|
|
The library automatically handles command line completion, syntax
|
|
errors, help messages and UNIX man page generation. It supports
|
|
programs with single or multiple commands (like [git]) and respect
|
|
most of the
|
|
{{:http://www.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap12.html}
|
|
POSIX} and
|
|
{{:http://www.gnu.org/software/libc/manual/html_node/Argument-Syntax.html}
|
|
GNU} conventions.
|
|
|
|
{1:manuals Manuals}
|
|
|
|
The following manuals are available.
|
|
|
|
{ul
|
|
{- The {{!page-tutorial}tutorial} makes you write your first command line
|
|
interface with Cmdliner.}
|
|
{- The {{!page-cookbook}cookbook} has a few off-the-shelf recipes,
|
|
tips about {{!page-cookbook.tip_src_structure}source code structure},
|
|
and {{!page-cookbook.blueprints}blueprints} to define your command lines
|
|
with Cmdliner.}
|
|
{- The {{!page-cli}command line interface manual} describes how command
|
|
lines and environment variables are parsed by Cmdliner and how command line
|
|
completion is performed. This can be communicated to the users of your
|
|
tools.}
|
|
{- The {{!page-tool_man}tool man page} manual describes how
|
|
Cmdliner generates man pages for your tools and their commands and how
|
|
you can format them.}
|
|
{- The {{!page-examples}examples page} has examples of a some
|
|
classic UNIX tools with their command line interface implemented by
|
|
Cmdliner.}}
|
|
|
|
{1:library Library [cmdliner]}
|
|
|
|
{!modules: Cmdliner}
|
|
{!modules:
|
|
Cmdliner.Arg
|
|
Cmdliner.Cmd
|
|
Cmdliner.Manpage
|
|
Cmdliner.Term
|
|
}
|