npm-check-updates icon indicating copy to clipboard operation
npm-check-updates copied to clipboard

Unhandled exception when `--target` has unexpected value

Open Ky6uk opened this issue 4 years ago • 4 comments

  • [x] I have searched for similar issues
  • [x] I am using the latest version of npm-check-updates
  • [x] I am using node >= 10.17

ncu --target woof will throw an error with the stack trace to the output channel. I'm not sure, but it feels like something unhandled.

Ky6uk avatar Sep 11 '20 12:09 Ky6uk

Yeah, we can do a nicer error message there. I'm going to wait until commander.js v7 when the choices feature is added.

https://github.com/tj/commander.js/pull/1331

raineorshine avatar Sep 11 '20 16:09 raineorshine

I strongly recommend you to use meow. For using meow, we don't need to wait any feature from upstream, because it's simple and powerful.

LitoMore avatar Sep 23 '20 03:09 LitoMore

I strongly recommend you to use meow.

Looks great, but I don't think it's worth switching cli frameworks just for validation, which can be easily implemented if we don't want to wait for commander.

For using meow, we don't need to wait any feature from upstream, because it's simple and powerful.

Actually, we're waiting for help text generation.

raineorshine avatar Sep 23 '20 14:09 raineorshine

Actually, we're waiting for help text generation.

I can help. :v:

LitoMore avatar Sep 23 '20 14:09 LitoMore

This was done at some point

raineorshine avatar Jun 25 '23 14:06 raineorshine