const process = require('process')
const commander = require('commander')
const package = require('../package.json')

commander
  .version(package.version, '-v, --version')
  .description(`视觉编辑器命令行工具 @${package.version}`)
  .usage('<command> [options]')
  .command('config <key> [val]', '全局配置')
  .command('create <name>', '创建一个组件')
  .command('build', '构建组件')
  .command('pack', '打包组件，用于线上/下分发')
  .command('publish [options]', '发布组件')
  // .command('serve <command>', '运行视觉编辑器')
  .parse(process.argv)
