Skip to content

Commit

Permalink
feat(cli): add command descriptions (#6991)
Browse files Browse the repository at this point in the history
  • Loading branch information
bluwy committed Feb 18, 2022
1 parent 88435e0 commit ffda8f0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/vite/src/node/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ cli

// dev
cli
.command('[root]') // default command
.command('[root]', 'start dev server') // default command
.alias('serve') // the command is called 'serve' in Vite's API
.alias('dev') // alias to align with the script name
.option('--host [host]', `[string] specify hostname`)
Expand Down Expand Up @@ -125,7 +125,7 @@ cli

// build
cli
.command('build [root]')
.command('build [root]', 'build for production')
.option('--target <target>', `[string] transpile target (default: 'modules')`)
.option('--outDir <dir>', `[string] output directory (default: dist)`)
.option(
Expand Down Expand Up @@ -181,7 +181,7 @@ cli

// optimize
cli
.command('optimize [root]')
.command('optimize [root]', 'pre-bundle dependencies')
.option(
'--force',
`[boolean] force the optimizer to ignore the cache and re-bundle`
Expand Down Expand Up @@ -212,7 +212,7 @@ cli
)

cli
.command('preview [root]')
.command('preview [root]', 'locally preview production build')
.option('--host [host]', `[string] specify hostname`)
.option('--port <port>', `[number] specify port`)
.option('--strictPort', `[boolean] exit if specified port is already in use`)
Expand Down

0 comments on commit ffda8f0

Please sign in to comment.