Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Bug in git tab completion: If git.showSignature = true is set globally, tab completion of commits is garbled
- X-seq: zsh-workers 44113
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: dana <dana@xxxxxxx>
- Subject: Re: Bug in git tab completion: If git.showSignature = true is set globally, tab completion of commits is garbled
- Date: Sun, 10 Mar 2019 16:20:51 +0000
- Cc: zsh-workers@xxxxxxx, Adrian Vollmer <zsh@xxxxxxxxxxxxxxx>
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= daniel.shahaf.name; h=date:from:to:cc:subject:message-id :references:mime-version:content-type:content-transfer-encoding :in-reply-to; s=fm2; bh=DPdZwWdyQS0jHwQDxvfm+KWaYCTQGGq3NgouldWN C+0=; b=kW9HbT0hU/s0rfVJoxYGaHc0GsCLDKClRJBfEBTv95e766saluD9OEAb hfjyVNc12AvS7HH9UJr0l6/++QNDxCgOvvXQMfqnRhfE48TAR3vQHl7iN157KetP pGgD5HEgbnaICh3fYFeH+/4lX0NYp4n+EtlB0C4sMCbcvNCarNIpLDMV88YQ22Jj fZDCYyAlqoTKJ5w23nZ1khHm1GmPCFEE3iRsNuZpC2qUIaH9kygUGmSRf/RpV+KC 6xcO1AMHIz/XCAyNy66ehS9BCZoEL9/hwDGc2DSzlao9Qs45O/EMBgv3a2S+s6Fn ci19WFAxnOpGA9Q3s0jpSZbh6wP3Ww==
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=DPdZwWdyQS0jHwQDxvfm+KWaYCTQGGq3NgouldWNC +0=; b=CVSWgtejrjpV0GHPYufpH2EL7eLIKKPAJ49hHer3wc4d4/OBkaBxvz6jc sGedsWPs2nJEOiPf68CC14i45mVi2eYfgM9CTQTCz7ULYIX36P5+z7hvU+sPii9v BixJIrLeUYWBeGTaaVHhhZMDRhMqQP0QIv3o15sFDantUcMOw1jNVz8KN3Sb4iPs vynAqBQ7W0FssEVLy6y9jBgID+Jhk0m8bn87EH82Yheyi7krjrMtEsd1mCiGs+nG Rm81ueC8BU9Sj+9c7TYHCZ52vHdpTYbYYonPyW+Ega+eDkC+YrF6LT3XPJPI0tga yunnIYLS6PzqA1E/3ujCIpHbS9CsQ==
- In-reply-to: <CD16F753-D0B8-44D6-B6FB-AEA50FA32307@dana.is>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <20190307192305.GA3173@av.sy.gs> <F03D392D-4496-4AD8-B196-BE8316799C62@dana.is> <7a2210af-0a67-4289-86c2-388e67eff32e@www.fastmail.com> <85B1B476-6F08-4AB0-8E30-B165A0E98082@dana.is> <57caa504-8287-4078-bd34-47ac7426e1db@www.fastmail.com> <CD16F753-D0B8-44D6-B6FB-AEA50FA32307@dana.is>
dana wrote on Sat, Mar 09, 2019 at 17:37:47 -0600:
> On 9 Mar 2019, at 10:43, Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx> wrote:
> >Huh. Odd, but I think we can live with that: we can just have _git
> >discard the hardcoded header line that git emits. All we really care
> >about is that future git versions will continue to emit that line. I
> >assume they will, for compatibility reasons.
>
> In that case, i think it would be something like this? I didn't test very
> extensively (not even sure which paths exactly lead to these commands), but it
> does seem to work for the scenario at hand
Looks good. Thanks. More below regarding the codepaths to these.
> +++ b/Completion/Unix/Command/_git
> @@ -5652,7 +5652,7 @@ __git_describe_branch () {
Looking at the callers of this, it should be used by «git checkout <TAB>» (one
of the alternatives is "basenames" of remote branches), refspecs in «git push
$remote …», etc; but an easier way to test this would be to run
.
compdef __git_describe_commit f
f <TAB>
.
interactively.
> @@ -6493,8 +6493,9 @@ __git_commit_objects () {
This function completes hashes of commits, as output by `git log --pretty=%h`.
It's used by _git-send-email. (I'm surprised that it isn't used by
_git-format-patch; those two commands are very similar.)
> @@ -6517,10 +6518,11 @@ __git_recent_commits () {
This is used by «git commit --fixup=<TAB>».
Cheers,
Daniel
Messages sorted by:
Reverse Date,
Date,
Thread,
Author