git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[RFC PATCH 0/2] Support enabling bash completion of all options

From
Ryan Zoeller <rtzoeller@rtzoeller.com>
Date
Aug 19, 2020, 17:50 UTC
Message-ID
<20200819175047.692962-1-rtzoeller@rtzoeller.com>

This series adds --git-completion-helper-all, which behaves similarly to --git-completion-helper but includes options which are typically hidden. An environment variable GIT_COMPLETION_SHOW_ALL is used to opt-in to this behavior.

I often prototype automated tooling around git by running commands locally until I'm satisfied with the behavior, then migrating them into a script. Having bash completion for some of the more obscure options is useful.

I wasn't sure how to add automated tests around this without making the tests overly brittle (e.g. depending on a verbatim list of options), so I welcome ideas and feedback.

-Ryan
Ryan Zoeller (2):
  parse-options: add --git-completion-helper-all
  completion: add GIT_COMPLETION_SHOW_ALL env var
 contrib/completion/git-completion.bash | 14 +++++++++++++-
 parse-options.c                        | 18 ++++++++++++------
 2 files changed, 25 insertions(+), 7 deletions(-)
-- 
2.28.0.260.g5fadab5a9c
Next: Ryan Zoeller
Message 1 of 9 in “Support enabling bash completion of all options”
  1. 0/2 Support enabling bash completion of all optionsRyan Zoeller, Aug 19, 2020
  2. 1/2 parse-options: add --git-completion-helper-allRyan Zoeller, Aug 19, 2020
  3. Junio C HamanoAug 19, 2020
  4. Ryan ZoellerAug 19, 2020
  5. Junio C HamanoAug 19, 2020
  6. 2/2 completion: add GIT_COMPLETION_SHOW_ALL env varRyan Zoeller, Aug 19, 2020
  7. 0/2 Support enabling bash completion of all optionsRyan Zoeller, Aug 19, 2020
  8. 1/2 parse-options: add --git-completion-helper-allRyan Zoeller, Aug 19, 2020
  9. 2/2 completion: add GIT_COMPLETION_SHOW_ALL env varRyan Zoeller, Aug 19, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.