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

bash completion on 4.0 broken?

From
Stephen Boyd <bebarino@gmail.com>
Date
Nov 17, 2009, 06:46 UTC
Message-ID
<4B0246C7.6020401@gmail.com>
When I try
    git show --pretty=<TAB><TAB>
I get a list of filenames and not the list of pretty formats.

I've debugged a little and see that the cur variable in _git_show () is set to '=' when it should be '--pretty='. So it looks like something is causing the command line to be split weirdly. Looking at the bash NEWS[1] for 4.0 I see

i.  The programmable completion code now uses the same set of characters as
    readline when breaking the command line into a list of words.

which causes me to believe this is why it's broken now. I've tried removing '=' from COMP_WORDBREAKS and that shows the list of formats correctly, but then causes the entire '--pretty=' to be replaced with the selected format.

Anyone else seeing the same problem or is my system just b0rked?

$ bash --version GNU bash, version 4.0.35(2)-release (x86_64-pc-linux-gnu)

References: [1] http://tiswww.case.edu/php/chet/bash/NEWS

Next: Michael J Gruber
Message 1 of 2 in “bash completion on 4.0 broken?”
  1. Stephen BoydNov 17, 2009
  2. Michael J GruberNov 17, 2009

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.