This repository was archived by the owner on Apr 26, 2021. It is now read-only.
v0.10.0
·
237 commits
to development
since this release
New features
- Fix [#48] - Implement special support for
--helpand--version. If--help
is encountered, print the original, full help text. The flags that trigger
this behavior can be overridden usingoptions.helpFlags(ex.{ helpFlags: ["-h"] }). To disable this behavior, pass it the empty list. Likewise, if
--versionis met, print the version of the CLI. The version can be
explicitly set viaoptions.version, but neodoc will otherwise fall back to
look for a package.json of the executing main module (seerequire.main).
The flags that trigger this behavior can be overriden using
options.versionFlags. Again, use the empty list to turn this behavior of
entirely.
Changes
-
Only parse repeating option-arguments repeatedly if the first argument is
NOT bound explicitly. Ex:usage: prog --foo=<bar>... qux $ prog --foo=10 qux => {"--foo": [10], "qux": true } $ prog --foo 10 qux => error! missing 'qux' (got consumed by --foo).
Fixes
- Fix case where parsing became extremely slow when
options.laxPlacementwas
enabled.