In the view that the nestjs commander is simply lacking a sensible documentation, I’m wasting time trying to figure out why this does not work:
@Option({
flags: '-m, --merchant [merchant]',
required: true,
description: 'merchant name',
choices: ['MyMerchant'],
})
merchant(val: string) {
return val;
}
I take it, the only value possible should be MyMerchant
, however the app keeps accepting all values…What needs to be done to make it work?
I’m starting regretting using this module instead of using the actual commander.