Skip to content
This repository has been archived by the owner on Jan 29, 2023. It is now read-only.

Commit

Permalink
fix: add -h and -v flags for single (#62)
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx authored Mar 21, 2018
1 parent bd173ec commit 009490b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions templates/src/command.js.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ Extra documentation goes here
<%- klass %>.flags = {
<%_ if (type === 'single') { _%>
// add --version flag to show CLI version
version: flags.version(),
version: flags.version({char: 'v'}),
// add --help flag to show CLI version
help: flags.help(),
help: flags.help({char: 'h'}),
<%_ } _%>
name: flags.string({char: 'n', description: 'name to print'}),
}
Expand Down
4 changes: 2 additions & 2 deletions templates/src/command.ts.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ hello myname from .src/<%- name %>.ts!
static flags = {
<%_ if (type === 'single') { _%>
// add --version flag to show CLI version
version: flags.version(),
version: flags.version({char: 'v'}),
// add --help flag to show CLI version
help: flags.help(),
help: flags.help({char: 'h'}),
<%_ } _%>
// flag with a value (-n, --name=VALUE)
Expand Down

0 comments on commit 009490b

Please sign in to comment.