Skip to content
This repository has been archived by the owner on Jan 5, 2024. It is now read-only.

typings command --help should include description of command #626

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mcclure
Copy link

@mcclure mcclure commented Jul 10, 2016

Say I type typings list --help. I get:

typings list

Options:
  [--production] List only production dependencies (omit dev dependencies)

Aliases: la, ll, ls

After reading this, I still don't know what typings list does. My expected behavior is that the --help for a command will explain the command, not just its options.

To address this, the attached patch copies the one-line description from commands.md into the individual command help() functions. I have also addressed minor style inconsistencies in the descriptions themselves (periods, backticks, inconsistent way the project in the current directory is referred to).

I have built this PR as described in the README but have not tested it. I can not figure out how to invoke the locally built typings after building. (Perhaps this information should be in the README).

@blakeembrey
Copy link
Member

Sounds good, but the documentation exists in https://github.com/typings/typings/blob/master/scripts/docs-commands.js - it's generated via a script. The script will need to be patched for this to work.

If you want to invoke it as a command, you can link it using npm link.

@mcclure
Copy link
Author

mcclure commented Jul 11, 2016

Okay. So i think the thing to do is to move the descriptions into the help() functions, then excise that field from docs-commands.js, and then running docs-commands.js will import the descriptions properly into the commands.md?

@blakeembrey
Copy link
Member

Sounds perfect 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants