-
I'd like to have an argument for a command only allow a list of valid values. Exactly like this commander example. Is this something possible with nest-commander? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
You could simulate this with a I can look into how to add this functionality otherwise, but it will probably be a breaking change to make the current commander API line up better with nest-commander's API |
Beta Was this translation helpful? Give feedback.
-
You can check within the function itself if status is a valid value and if it is not then raise an exception. |
Beta Was this translation helpful? Give feedback.
You could simulate this with a
required
option which will pretty much act like an argument, but come in through theoptions
parameter instead.I can look into how to add this functionality otherwise, but it will probably be a breaking change to make the current commander API line up better with nest-commander's API