Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Alias not shown in root help #1373

Open
akshaybabloo opened this issue Apr 10, 2021 · 3 comments
Open

Alias not shown in root help #1373

akshaybabloo opened this issue Apr 10, 2021 · 3 comments
Labels
area/lib Methods and functions that exist in the cobra library and consumed by users kind/feature A feature request for cobra; new or enhanced behavior

Comments

@akshaybabloo
Copy link

This issue is related to #633.

For example:

> someTool --help

Available Commands:
  help        Help about any command
  target      Print the version number of Hugo

> someTool target --help

Usage:
  nvmefc target [command]

Aliases:
  target, t, tar

Available Commands:
  list        Print the version number of Hugo

I would be nice to have an output something like:

Available Commands:
  help                 Help about any command
  target (t, tar)      Print the version number of Hugo
@akshaybabloo akshaybabloo changed the title Alias not shown in root Alias not shown in root help Apr 10, 2021
@github-actions
Copy link

This issue is being marked as stale due to a long period of inactivity

@akshaybabloo
Copy link
Author

Ping

@johnSchnake
Copy link
Collaborator

I think the issue with this is that some people use the Alias as a catchall to help the users but don't necessarily want to recommend it to them nor have it it elevated in the help to be as visible.

It can make the output look particularly poor if you consider that I was just looking at another issue about aliases and case-sensitivity. So you could have aliases currently that just have different casing which you definitely wouldn't wan't shown everywhere and messing with the default help output.

Going to leave open for a bit to let anyone else comment but without further motivation or reaction from the community I'd rather just close this.

@johnSchnake johnSchnake added area/lib Methods and functions that exist in the cobra library and consumed by users kind/feature A feature request for cobra; new or enhanced behavior waiting-user-response and removed kind/stale labels Feb 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/lib Methods and functions that exist in the cobra library and consumed by users kind/feature A feature request for cobra; new or enhanced behavior
Projects
None yet
Development

No branches or pull requests

3 participants