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

RFE: env var for disabling descriptions #1937

Closed
scop opened this issue Mar 26, 2023 · 2 comments · Fixed by #1938
Closed

RFE: env var for disabling descriptions #1937

scop opened this issue Mar 26, 2023 · 2 comments · Fixed by #1938

Comments

@scop
Copy link
Contributor

scop commented Mar 26, 2023

In scop/bash-completion#905, we've added fallback 3rd party completion loaders for various known commands, including some cobra powered ones, and more are expected to be added later. However, as it stands, this mechanism does not have any way for users to specify --no-descriptions if that's their preference.

We could create a bash-completion specific way to accomplish this, but in my opinion this would be better placed in cobra proper. An environment variable would serve this nicely I think: something like COBRA_COMPLETION_NO_DESCRIPTIONS(=non-empty-value) could be equivalent as if --no-descriptions was passed in the generator command line.

@marckhouzam
Copy link
Collaborator

Agreed. I've been thinking about this for a long time but never actually pulled the trigger. Thanks for bringing it up.

@scop
Copy link
Contributor Author

scop commented Mar 27, 2023

Quick take on it in #1938

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

Successfully merging a pull request may close this issue.

2 participants