git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jonathan Nieder <jrnieder@gmail.com>
To: Felipe Contreras <felipe.contreras@gmail.com>
Cc: git@vger.kernel.org, "SZEDER Gábor" <szeder@ira.uka.de>
Subject: Re: [PATCH for maint] git-completion: fix zsh support
Date: Fri, 6 May 2011 04:59:20 -0500	[thread overview]
Message-ID: <20110506095920.GA1635@elie> (raw)
In-Reply-To: <BANLkTikk1wfaC4Aic4iyJZXbZ5kkuEDxaA@mail.gmail.com>

Felipe Contreras wrote:

> No, the scope remains local.

Is this local in the sense of typeset used in ksh functions declared
as "function f" or local in the sense of typeset used in ksh functions
declared as "f ()"?  If the latter, I think you misunderstood me --- I
never meant to suggest otherwise.

> In fact, if you follow the link I posted, that's precisely the fix the
> zsh guys were pushing for. And the it is already merged:
> http://zsh.git.sourceforge.net/git/gitweb.cgi?p=zsh/zsh;a=commitdiff;h=e880604f029088f32fb1ecc39213d720ae526aaa

Now this changes things (since it amounts to a guarantee that the
bash completion emulation has already extracted all it needs from
$words before calling a completion function).  What happens if someone
calls "compgen -F" after words is hidden?

> Well, it's hosted on debian.org, and I haven't seen it used anywhere
> else. I just don't know how else to identify that project.

Here you go: http://pkgs.fedoraproject.org/gitweb/?p=bash-completion.git;a=tree

It's called bash-completion or bash_completion.  It really has
basically nothing to do with Debian; they just are using Debian
infrastructure.  But hey, call it what you want.  I don't like
arguing.

> I think the simplest fix is the one I'm proposing

I'm happy with it as long as the zsh people are committed to making
sure it continues to work (which it sounds like they are, luckily).
I suppose it is intended to obsolete the third patch from Gábor's
series?  Could you provide an explanation for the commit log,
something to the effect that

 - the words array has special meaning
 - that produces such-and-such puzzling symptoms
 - zsh 4.3.12 (?) will fix it by using "typeset -h" to hide it when
   running completion functions designed for bash
 - we can make the same fix to work correctly with earlier versions of
   zsh, and that's what this patch does

?

Sorry I have been so dense --- hopefully I understand it roughly
now.

Regards,
Jonathan

  reply	other threads:[~2011-05-06  9:59 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-05 14:24 [PATCH for maint branch] git-completion: fix zsh support Felipe Contreras
2011-05-05 17:34 ` Junio C Hamano
2011-05-05 19:29   ` Felipe Contreras
2011-05-05 18:59 ` SZEDER Gábor
2011-05-05 19:52   ` [PATCH for maint] " Felipe Contreras
2011-05-05 23:25     ` Jonathan Nieder
2011-05-06  4:51       ` Junio C Hamano
2011-05-06  5:27         ` Jonathan Nieder
2011-05-06  9:34           ` Felipe Contreras
2011-05-06  9:27       ` Felipe Contreras
2011-05-06  9:59         ` Jonathan Nieder [this message]
2011-05-06 10:06           ` Jonathan Nieder
2011-05-09 13:51           ` Felipe Contreras
2011-05-06  1:28     ` Jonathan Nieder

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20110506095920.GA1635@elie \
    --to=jrnieder@gmail.com \
    --cc=felipe.contreras@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=szeder@ira.uka.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).