<feed xmlns='http://www.w3.org/2005/Atom'>
<title>git/contrib/completion, branch v2.30.2</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/git/git.git/
</subtitle>
<id>https://git.shady.money/git/atom?h=v2.30.2</id>
<link rel='self' href='https://git.shady.money/git/atom?h=v2.30.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/'/>
<updated>2020-12-08T23:11:22Z</updated>
<entry>
<title>Merge branch 'fc/zsh-completion'</title>
<updated>2020-12-08T23:11:22Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-12-08T23:11:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=7d92da37871dceb732a56f5a3aecf0be872a40ab'/>
<id>urn:sha1:7d92da37871dceb732a56f5a3aecf0be872a40ab</id>
<content type='text'>
Hotfix for a recent breakage.

* fc/zsh-completion:
  completion: bash: fix gitk alias regression
  completion: zsh: fix file completion regression
</content>
</entry>
<entry>
<title>completion: bash: fix gitk alias regression</title>
<updated>2020-12-07T21:39:53Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2020-12-05T07:10:23Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=076496457e1abe3058d48cb5c387d1face704494'/>
<id>urn:sha1:076496457e1abe3058d48cb5c387d1face704494</id>
<content type='text'>
Long time ago when the _git_complete helper was introduced, _gitk was
replaced with __gitk_main, and a placeholder for backwards compatibility
pointing to __git_wrap_main_gitk was left in place.

When "__git_complete gitk __gitk_main" was called, that created the
__git_wrap__gitk_main helper, which is just basically "__git_func_wrap
__gitk_main" plus `complete` options.

Unfortunately the commit b0a4b2d257 (completion: add support for
backwards compatibility, 2012-05-19) missed a previous instance of a
call to _gitk in _git_gitk

So, basically we had __git_wrap__git_main -&gt; __git_func_wrap __git_main -&gt;
__git_complete_command gitk -&gt; _git_gitk -&gt; _gitk -&gt;
__git_wrap__gitk_main -&gt; __git_func_wrap __gitk_main -&gt; __gitk_main.

There was never any need to call __git_func_wrap twice. Since _git_gitk
is always called inside the wrapper, it can call __gitk_main directly.

And then, in commit 441ecdab37 (completion: bash: remove old compat
wrappers, 2020-10-27) _gitk was removed, which triggers the following
error:

  _git_gitk:9: command not found: _gitk

Let's call the correct function: __gitk_main.

Cc: SZEDER Gábor &lt;szeder.dev@gmail.com&gt;
Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>completion: zsh: fix file completion regression</title>
<updated>2020-12-01T18:32:40Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2020-12-01T00:54:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=c5dd0c861ab0db5ad1ecaf9508bdddca83c5cc6e'/>
<id>urn:sha1:c5dd0c861ab0db5ad1ecaf9508bdddca83c5cc6e</id>
<content type='text'>
Turns out we always need to set the ignored prefix (compset) to have
similar behavior as in default Bash.

The issue can be seen with:

  git show master:&lt;tab&gt;

Commit 94b2901cfe wrongly removed it.

Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'fc/bash-completion-alias-of-alias'</title>
<updated>2020-11-25T23:24:51Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-11-25T23:24:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=fd6445a0b8346d0dea6482af682f2116229f6436'/>
<id>urn:sha1:fd6445a0b8346d0dea6482af682f2116229f6436</id>
<content type='text'>
The command line completion script (in contrib/) learned to expand
commands that are alias of alias.

* fc/bash-completion-alias-of-alias:
  completion: bash: improve alias loop detection
  completion: bash: check for alias loop
  completion: bash: support recursive aliases
</content>
</entry>
<entry>
<title>completion: bash: improve alias loop detection</title>
<updated>2020-11-17T18:57:46Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2020-11-12T22:34:52Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=e4c75edb52acab8c90520ceedab4326b972cc0af'/>
<id>urn:sha1:e4c75edb52acab8c90520ceedab4326b972cc0af</id>
<content type='text'>
It is possible for the name of an alias to end with the name of another
alias, in which case the code will incorrectly detect a loop.

We can fix that by adding an extra space between words.

Suggested-by: SZEDER Gábor &lt;szeder.dev@gmail.com&gt;
Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'sd/prompt-local-variable'</title>
<updated>2020-11-11T21:18:38Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-11-11T21:18:38Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=fb628ab129dc2a29581e05edd886e3dc16a4ac49'/>
<id>urn:sha1:fb628ab129dc2a29581e05edd886e3dc16a4ac49</id>
<content type='text'>
Code clean-up.

* sd/prompt-local-variable:
  git-prompt.sh: localize `option` in __git_ps1_show_upstream
</content>
</entry>
<entry>
<title>completion: bash: check for alias loop</title>
<updated>2020-11-10T02:09:21Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2020-11-10T02:03:43Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=c2822a842dc993722a9d6f8226189312b95d8801'/>
<id>urn:sha1:c2822a842dc993722a9d6f8226189312b95d8801</id>
<content type='text'>
We don't want to be stuck in an endless cycle.

Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>completion: bash: support recursive aliases</title>
<updated>2020-11-10T02:09:21Z</updated>
<author>
<name>Felipe Contreras</name>
<email>felipe.contreras@gmail.com</email>
</author>
<published>2020-11-10T02:03:42Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=9414938c348f47c76dcea7826ea0b22adb585300'/>
<id>urn:sha1:9414938c348f47c76dcea7826ea0b22adb585300</id>
<content type='text'>
It is possible to have recursive aliases like:

  l = log --oneline
  lg = l --graph

So the completion should detect such aliases as well.

Signed-off-by: Felipe Contreras &lt;felipe.contreras@gmail.com&gt;
Signed-off-by: Junio C Hamano &lt;gitster@pobox.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'fc/zsh-completion'</title>
<updated>2020-11-09T22:06:29Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-11-09T22:06:29Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=4560eae44f43d6cda027550dbc814bb4b1a9f638'/>
<id>urn:sha1:4560eae44f43d6cda027550dbc814bb4b1a9f638</id>
<content type='text'>
Zsh autocompletion (in contrib/) update.

* fc/zsh-completion: (29 commits)
  zsh: update copyright notices
  completion: bash: remove old compat wrappers
  completion: bash: cleanup cygwin check
  completion: bash: trivial cleanup
  completion: zsh: add simple version check
  completion: zsh: trivial simplification
  completion: zsh: add alias descriptions
  completion: zsh: improve command tags
  completion: zsh: refactor command completion
  completion: zsh: shuffle functions around
  completion: zsh: simplify file_direct
  completion: zsh: simplify nl_append
  completion: zsh: trivial cleanup
  completion: zsh: simplify direct compadd
  completion: zsh: simplify compadd functions
  completion: zsh: fix splitting of words
  completion: zsh: add missing direct_append
  completion: fix conflict with bashcomp
  completion: zsh: fix completion for --no-.. options
  completion: bash: remove zsh wrapper
  ...
</content>
</entry>
<entry>
<title>Merge branch 'lo/zsh-completion'</title>
<updated>2020-11-02T21:17:40Z</updated>
<author>
<name>Junio C Hamano</name>
<email>gitster@pobox.com</email>
</author>
<published>2020-11-02T21:17:40Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/git/commit/?id=bbdbe08bd73fa9dcd92c613874d06fe719059326'/>
<id>urn:sha1:bbdbe08bd73fa9dcd92c613874d06fe719059326</id>
<content type='text'>
Update instructions for command line completion (in contrib/) for zsh.

* lo/zsh-completion:
  completion: fix zsh installation instructions
</content>
</entry>
</feed>
