Way to differentiate "root" description from "default command" description
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 11.5k
- Forks
- 1k
- PR merge metrics
- No merged PRs in 30d
Description
Right now, it seems that the description listed above the Commands section is just pulled from the description field of the default command. I have a use case where I want the "root" level tool description to be different than what is shown in the line for the default command. Is this possible? And if not, can there be an option for that (I'm thinking it would be similar to the scriptName method, maybe scriptDescription?)
Current
$ npm start -- --help
> software-update-checker-cli@0.4.0 start D:\Repos\software-update-checker-cli
> ts-node src/index.ts "--help"
software-update-checker-win.exe [add|view|edit|remove]
Check if installed software has updates available
Commands:
software-update-checker-win.exe [add|view|edit|remove] Check if installed software has updates available [default]
Desired:
$ npm start -- --help
> software-update-checker-cli@0.4.0 start D:\Repos\software-update-checker-cli
> ts-node src/index.ts "--help"
software-update-checker-win.exe [add|view|edit|remove]
Check if installed software has updates available
Commands:
software-update-checker-win.exe [add|view|edit|remove] Launch interactive console [default]
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No yargs files or tests are named; the example identifies src/index.ts as the consuming entry point and mentions the existing scriptName method. Start by tracing --help output and how the default command description is reused, then verify that the root and default-command descriptions can be supplied independently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100