| Title: | Command-Line Interface Specification Language |
|---|---|
| Description: | Define a command-line interface by just giving it a description in the specific format. |
| Authors: | Edwin de Jonge [aut, cre] (ORCID: <https://orcid.org/0000-0002-6580-4718>) |
| Maintainer: | Edwin de Jonge <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.7.2 |
| Built: | 2026-05-11 07:03:21 UTC |
| Source: | https://github.com/docopt/docopt.r |
docopt helps you to define an interface for your command-line app, and automatically generate a parser for it.
For more information see http://docopt.org
Maintainer: Edwin de Jonge [email protected] (ORCID)
Useful links:
args based on command-line interface described in doc.docopt creates your command-line interface based on its
description that you pass as doc.
Such description can contain
–options, <positional-argument>, commands, which could be
[optional], (required), (mutually | exclusive) or repeated...
docopt( doc, args = commandArgs(TRUE), name = NULL, help = TRUE, version = NULL, strict = FALSE, strip_names = !strict, quoted_args = !strict )docopt( doc, args = commandArgs(TRUE), name = NULL, help = TRUE, version = NULL, strict = FALSE, strip_names = !strict, quoted_args = !strict )
doc |
|
args |
|
name |
Currently not used |
help |
|
version |
|
strict |
|
strip_names |
if |
quoted_args |
if |
named list with all parsed options, arguments and commands.
"Usage: my_program.R [-hso FILE] [--quiet | --verbose] [INPUT ...] -h --help show this -s --sorted sorted output -o FILE specify output file [default: ./test.txt] --quiet print less text --verbose print more text" -> doc docopt(doc, "-s --quiet")"Usage: my_program.R [-hso FILE] [--quiet | --verbose] [INPUT ...] -h --help show this -s --sorted sorted output -o FILE specify output file [default: ./test.txt] --quiet print less text --verbose print more text" -> doc docopt(doc, "-s --quiet")