Skip to content

Show the type of arguments in help message? #5153

Answered by epage
tigerros asked this question in Q&A
Discussion options

You must be logged in to vote

There is an argument parser for another language that does this; I wish I could remember which.

If we did this, it could work to fill in similar to [possible values: foo, bar] in style.

However, I'm concerned about

  • Clutter in the help output
  • Not being in the user's terms (while most CLI users are programmers, not all are), even if its "unsigned 32 bit integer".

However, the value_name fills a similar role and I think it'd be a worthwhile to look into leveraging that. long and id are more akin to a field name while value_name is more akin to the type (in flags, positionals are weird in that they need to convey both). Framing this way, makes me feel like we could have a type associated te…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@tigerros
Comment options

Answer selected by tigerros
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants