-
-
Notifications
You must be signed in to change notification settings - Fork 42
Open
Labels
enhancementNew feature or requestNew feature or requesthelp wantedpull requests welcomepull requests welcome
Description
Hi,
I'm not sure what's the best place to discuss feature, feel free to close and direct me to a better place
Some users of our cli mistype an argument name (eg the cli expects --dry-run and they type --dryrun).
If would be useful to have a strict mode that stops the process if there is an unknown error
(eg. invalid parameter "dryrun")
I tried to implement it using unknown
unknown: (param) => {param[0] === '-' ? console.error("invalid parameter",param) || process.exit(1) : true},
however,
- it would be nice to have to have a second parameter "type" on unknown (ie "-" "--" "" if alias, normal, or argv.)
- I can't figure out how to handle valid params that are int (eg aren't listed into boolean or string), is there an "any" or "integer" option?
X+
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or requesthelp wantedpull requests welcomepull requests welcome