Skip to content

Commit

Permalink
Add Chinese translation for .name and .usage section
Browse files Browse the repository at this point in the history
  • Loading branch information
shadowspawn committed Aug 12, 2019
1 parent b19b58e commit b939242
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions Readme_zh-CN.md
Expand Up @@ -22,7 +22,7 @@
- [Git 风格的子命令](#git-%e9%a3%8e%e6%a0%bc%e7%9a%84%e5%ad%90%e5%91%bd%e4%bb%a4)
- [自动化帮助信息 --help](#%e8%87%aa%e5%8a%a8%e5%8c%96%e5%b8%ae%e5%8a%a9%e4%bf%a1%e6%81%af---help)
- [自定义帮助](#%e8%87%aa%e5%ae%9a%e4%b9%89%e5%b8%ae%e5%8a%a9)
- [.usage and .name](#usage-and-name)
- [.usage .name](#usage-%e5%92%8c-name)
- [.outputHelp(cb)](#outputhelpcb)
- [.helpOption(flags, description)](#helpoptionflags-description)
- [.help(cb)](#helpcb)
Expand Down Expand Up @@ -445,18 +445,17 @@ Examples:
$ custom-help -h
```
### .usage and .name
### .usage .name
These allow you to customise the usage description in the first line of the help. The name is otherwise
deduced from the (full) program arguments. Given:
这两个选项让你可以自定义在帮助信息第一行中显示的命令使用描述(description),并且描述是从(完整的)命令参数中推导出来的。例如:
```js
program
.name("my-command")
.usage("[global options] command")
```
The help will start with:
帮助信息会以此开头:
```Text
Usage: my-command [global options] command
Expand Down

0 comments on commit b939242

Please sign in to comment.