From 809db105a6ff738e915cf979c3855fc8f459817a Mon Sep 17 00:00:00 2001 From: Sun Haoran Date: Mon, 27 Jan 2020 18:08:25 +0800 Subject: [PATCH] fix: stop running command with help or version (#64) --- src/CAC.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/CAC.ts b/src/CAC.ts index a56e5cb..53143f3 100644 --- a/src/CAC.ts +++ b/src/CAC.ts @@ -208,10 +208,12 @@ class CAC extends EventEmitter { if (this.options.help && this.showHelpOnExit) { this.outputHelp() + run = false } if (this.options.version && this.showVersionOnExit) { this.outputVersion() + run = false } const parsedArgv = { args: this.args, options: this.options }