Skip to content

Commit

Permalink
fix: only show examples if generating hello command
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Apr 4, 2018
1 parent 12869c4 commit 147a317
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions templates/src/command.ts.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ export default class <%- klass %> extends Command {
<%_ } _%>
static description = 'describe the command here'
<%_ if (name === 'hello') { _%>
static examples = [
`$ <%- cmd %>
hello world from ./src/<%- name %>.ts!
`,
]
<%_ } _%>
static flags = {
<%_ if (type === 'single') { _%>
// add --version flag to show CLI version
Expand Down

0 comments on commit 147a317

Please sign in to comment.