mirror of
https://github.com/all-contributors/cli.git
synced 2025-01-09 21:46:29 +00:00
fix: scriptName + improving usage messages (#305)
* Improving usage messages + fixing scriptName * Fixes post-review
This commit is contained in:
parent
f1a336d9f3
commit
d3b8f8889d
2 changed files with 9 additions and 13 deletions
|
@ -41,8 +41,8 @@ as you want/need to. Nobody can ask any more of you than that.
|
||||||
As a maintainer, you're fine to make your branches on the main repo or on your own fork. Either
|
As a maintainer, you're fine to make your branches on the main repo or on your own fork. Either
|
||||||
way is fine.
|
way is fine.
|
||||||
|
|
||||||
When we receive a pull request, a travis build is kicked off automatically (see the `.travis.yml`
|
When we receive a pull request, a Circle CI build is kicked off automatically (see the `.circleci/`
|
||||||
for what runs in the travis build). We avoid merging anything that breaks the travis build.
|
directory for what runs in the CI pipeline). We avoid merging anything that breaks the CI pipeline.
|
||||||
|
|
||||||
Please review PRs and focus on the code rather than the individual. You never know when this is
|
Please review PRs and focus on the code rather than the individual. You never know when this is
|
||||||
someone's first ever PR and we want their experience to be as positive as possible, so be
|
someone's first ever PR and we want their experience to be as positive as possible, so be
|
||||||
|
@ -56,8 +56,8 @@ about that.
|
||||||
|
|
||||||
## Release
|
## Release
|
||||||
|
|
||||||
Our releases are automatic. They happen whenever code lands into `master`. A travis build gets
|
Our releases are automatic. They happen whenever code lands into `master`. A Circle CI build
|
||||||
kicked off and if it's successful, a tool called
|
build gets kicked off and if it's successful, a tool called
|
||||||
[`semantic-release`](https://github.com/semantic-release/semantic-release) is used to
|
[`semantic-release`](https://github.com/semantic-release/semantic-release) is used to
|
||||||
automatically publish a new release to npm as well as a changelog to GitHub. It is only able to
|
automatically publish a new release to npm as well as a changelog to GitHub. It is only able to
|
||||||
determine the version and whether a release is necessary by the git commit messages. With this
|
determine the version and whether a release is necessary by the git commit messages. With this
|
||||||
|
|
14
src/cli.js
14
src/cli.js
|
@ -16,22 +16,18 @@ const cwd = process.cwd()
|
||||||
const defaultRCFile = path.join(cwd, '.all-contributorsrc')
|
const defaultRCFile = path.join(cwd, '.all-contributorsrc')
|
||||||
|
|
||||||
const yargv = yargs
|
const yargv = yargs
|
||||||
|
.scriptName('all-contributors')
|
||||||
.help('help')
|
.help('help')
|
||||||
.alias('h', 'help')
|
.alias('h', 'help')
|
||||||
.alias('v', 'version')
|
.alias('v', 'version')
|
||||||
.version()
|
.version()
|
||||||
.recommendCommands()
|
.recommendCommands()
|
||||||
.command('generate', 'Generate the list of contributors')
|
.command('generate', `Generate the list of contributors\n\nUSAGE: all-contributors generate`)
|
||||||
.usage('Usage: $0 generate')
|
.command('add', `Add a new contributor\n\nUSAGE: all-contributors add <username> <comma-separated contributions>`)
|
||||||
.command('add', 'add a new contributor')
|
.command('init', `Prepare the project to be used with this tool\n\nUSAGE: all-contributors init`)
|
||||||
.usage('Usage: $0 add <username> <contribution>')
|
|
||||||
.command('init', 'Prepare the project to be used with this tool')
|
|
||||||
.usage('Usage: $0 init')
|
|
||||||
.command(
|
.command(
|
||||||
'check',
|
'check',
|
||||||
'Compares contributors from the repository with the ones credited in .all-contributorsrc',
|
`Compare contributors from the repository with the ones credited in .all-contributorsrc'\n\nUSAGE: all-contributors check`)
|
||||||
)
|
|
||||||
.usage('Usage: $0 check')
|
|
||||||
.boolean('commit')
|
.boolean('commit')
|
||||||
.default('files', ['README.md'])
|
.default('files', ['README.md'])
|
||||||
.default('contributorsPerLine', 7)
|
.default('contributorsPerLine', 7)
|
||||||
|
|
Loading…
Reference in a new issue