Hi all,
I'm happy to announce the release of argparse 0.7.0.
Argparse is a feature-rich command line parser for Lua; it supports
positional arguments, options, flags, optional arguments, subcommands
and more.
The project was created and maintained by Peter Melnichenko who sadly
is no longer with us
(http://lua-users.org/lists/lua-l/2018-11/msg00114.html). The luarocks
organisation has taken over maintainership of the argparse project,
which is now hosted at https://github.com/luarocks/argparse/
This year as part of the Google Summer of Code, Paul Ouellettee added
a new feature to generate of command line completion scripts, which
allows any program that uses argparse to get tab completions in bash,
zsh and fish.
Major changes:
- Added support for generating shell completion scripts for Bash,
Zsh, and Fish using the Parser methods `:get_bash_complete()`,
`:get_zsh_complete()`, and `:get_fish_complete()`. The Parser methods
`:add_complete()` and `:add_complete_command()` add a `--completion`
option or `completion` command to the parser.
- Added `:add_help_command()` method to Parser and Command objects.
The help command shows help for the specified subcommand.
- Added `choices` option and argument property for specifying a set
of acceptable values for the argument.
- Added `summary` command property for specifying the description
shown in the parent parser's help message.
- The location of the help flag in usage and help messages is now
determined by when it is added to the parser, rather than always being
the last option. By default it is now the first option.
Note that the documentation at https://argparse.readthedocs.io/ will
not be updated for a few weeks, as we're awaiting permissions to
publish there.
Regards,
Daurnimator