@artus-cli/plugin-version
Advanced tools
+3
-3
@@ -16,5 +16,5 @@ "use strict"; | ||
| // intercept root command and show version | ||
| this.program.useInCommand(rootCommand, async (ctx, next) => { | ||
| const { args } = ctx; | ||
| if (args.version) { | ||
| this.program.use(async (ctx, next) => { | ||
| const { args, fuzzyMatched } = ctx; | ||
| if (fuzzyMatched === rootCommand && args.version) { | ||
| return console.info(this.program.version); | ||
@@ -21,0 +21,0 @@ } |
+1
-1
| { | ||
| "name": "@artus-cli/plugin-version", | ||
| "version": "1.0.1", | ||
| "version": "1.0.2", | ||
| "description": "version plugin for artus cli", | ||
@@ -5,0 +5,0 @@ "homepage": "", |
5462
0.44%