const {Command, flags} = require('@anycli/command') <%_ const klass = _.upperFirst(_.camelCase(name.split(':').slice(-1).join(':') + ':command')) _%> class <%- klass %> extends Command { async run() { const {flags} = this.parse(<%- klass %>) const name = flags.name || 'world' this.log(`hello ${name} from <%- name %>!`) } } <%- klass %>.flags = { <%_ if (type === 'single') { _%> // add --version flag to show CLI version version: flags.version(), // add --help flag to show CLI version help: flags.help(), <%_ } _%> name: flags.string({char: 'n', description: 'name to print'}), } module.exports = <%- klass %>