You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using yargs .describe method to generate usage information, is there some way to prevent yargs from auto-adding information about type, default value, choices etc.?
I.e. the following
.option('foo', {
type: 'string',
choices: ['bar','baz'],
required: true,
default: 'bar',
description: 'The most important option of all'
})
results in this output when doing --help:
--foo The most important option of all [string] [required] [choices: "bar", "baz"] [default: "bar"]
I have to confess I find that to be a bit ugly, and it is out of line with how help texts are generally formatted in linux. Also, on longer description texts that include line breaks, it breaks formatting.
I haven't found anything in the docs. Is there some way to suppress generation of the bracketed [] parts, without having to completely give up using the describe feature?
The text was updated successfully, but these errors were encountered:
@bcoe Thanks for the awesome awesome lib. As mentioned in the issue, and also the open #2156, any update on having this change introduced?
Apart from the programmers, the end users generally don't care about the type or can get confused by the mention of the type in help!
Can this feature be released in yargs@next, per the readme? It appears that yargs@next is several versions behind latest, and does not include it as of writing
When using yargs .describe method to generate usage information, is there some way to prevent yargs from auto-adding information about type, default value, choices etc.?
I.e. the following
results in this output when doing --help:
I have to confess I find that to be a bit ugly, and it is out of line with how help texts are generally formatted in linux. Also, on longer description texts that include line breaks, it breaks formatting.
I haven't found anything in the docs. Is there some way to suppress generation of the bracketed
[]
parts, without having to completely give up using the describe feature?The text was updated successfully, but these errors were encountered: