mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat(cli): add command description
This commit is contained in:
parent
99fb78edb5
commit
c29372b114
@ -11,27 +11,49 @@ import { changelog } from './commands/changelog';
|
||||
import { buildSite } from './commands/build-site';
|
||||
import { commitLint } from './commands/commit-lint';
|
||||
|
||||
command('dev').action(dev);
|
||||
command('dev')
|
||||
.description('Run webpack dev server')
|
||||
.action(dev);
|
||||
|
||||
command('lint').action(lint);
|
||||
command('lint')
|
||||
.description('Run eslint and stylelint')
|
||||
.action(lint);
|
||||
|
||||
command('clean').action(clean);
|
||||
command('test')
|
||||
.description('Run unit tests through jest')
|
||||
.option(
|
||||
'--watch',
|
||||
'Watch files for changes and rerun tests related to changed files'
|
||||
)
|
||||
.option(
|
||||
'--clearCache',
|
||||
'Clears the configured Jest cache directory and then exits'
|
||||
)
|
||||
.action(test);
|
||||
|
||||
command('clean')
|
||||
.description('Clean all dist files')
|
||||
.action(clean);
|
||||
|
||||
command('build')
|
||||
.description('Compile components in production mode')
|
||||
.option('--watch', 'Watch file change')
|
||||
.action(build);
|
||||
|
||||
command('release').action(release);
|
||||
command('release')
|
||||
.description('Compile components and release it')
|
||||
.action(release);
|
||||
|
||||
command('changelog').action(changelog);
|
||||
command('build-site')
|
||||
.description('Compile site in production mode')
|
||||
.action(buildSite);
|
||||
|
||||
command('build-site').action(buildSite);
|
||||
command('changelog')
|
||||
.description('Generate changelog')
|
||||
.action(changelog);
|
||||
|
||||
command('commit-lint').action(commitLint);
|
||||
|
||||
command('test')
|
||||
.option('--watch')
|
||||
.option('--clearCache')
|
||||
.action(test);
|
||||
command('commit-lint')
|
||||
.description('Lint commit message')
|
||||
.action(commitLint);
|
||||
|
||||
parse(process.argv);
|
||||
|
Loading…
x
Reference in New Issue
Block a user