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

Re: [PATCH v4 (for maint)] git-completion: fix zsh support

From
Junio C Hamano <gitster@pobox.com>
Date
May 9, 2011, 23:25 UTC
Message-ID
<7v1v07o3rs.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20110509225307.GG22908@elie>
Jonathan Nieder <jrnieder@gmail.com> writes:
> An alternative possibility if we need this fixed in the v1.7.5.x
> series (do we?) would be cherry-picking the fix from
> sg/completion-updates on top of maint.

As contrib/ material, I personally don't think we would care strongly enough to bother.

Show 11 quoted lines
> To clarify the trade-offs:
>
>  - in terms of lines of code, the fix itself in sg/completion-updates
>    and this fix are about the same size.  But the sg/completion-updates
>    version relies on a code cleanup.
>
>  - the fix in sg/completion-updates is less likely to be broken by
>    future changes in the bashcompinit library.
>
>  - this fix is conceptually simpler.  In a way, the fix in
>    sg/completion-updates only works by accident.

Hmm, zsh does not want to see "word" getting localized by the user because it has a special semantics associated with it. Szeder avoids localizing it. Felipe sidesteps the issue by stripping the funny special semantics from the variable. I guess both have a similar degree of conceptual simplicity.

One big thing going for this patch is that this is the blessed solution zsh folks themselves like to use, no? The repeated mention "zsh bashinit bug" in the code seems to suggest that it is the case.

I do not mind reverting sg/completion-updates from 'next' (please remind me that I need to resurrect your "private shopt shim" separately if we go this route) and applying a cleaned-up version of this one.

Thanks.
Previous: Felipe ContrerasNext: Jonathan Nieder
Message 9 of 19 in “git-completion: fix zsh support”
  1. git-completion: fix zsh supportFelipe Contreras, May 9, 2011
  2. Jonathan NiederMay 9, 2011
  3. Felipe ContrerasMay 9, 2011
  4. git-completion: fix zsh supportFelipe Contreras, May 9, 2011
  5. Jonathan NiederMay 9, 2011
  6. Felipe ContrerasMay 9, 2011
  7. Jonathan NiederMay 9, 2011
  8. Felipe ContrerasMay 9, 2011
  9. Junio C HamanoMay 9, 2011
  10. Jonathan NiederMay 9, 2011
  11. 0/2 git-completion: fix zsh supportJonathan Nieder, May 10, 2011
  12. 1/2 completion: suppress zsh's special 'words' variableJonathan Nieder, May 10, 2011
  13. Jonathan NiederMay 10, 2011
  14. Felipe ContrerasMay 10, 2011
  15. Felipe ContrerasMay 10, 2011
  16. 2/2 completion: move private shopt shim for zsh to __git_ namespaceJonathan Nieder, May 10, 2011
  17. Felipe ContrerasMay 10, 2011
  18. Jonathan NiederMay 10, 2011
  19. Felipe ContrerasMay 10, 2011

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.