1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-09-09 00:11:25 +02:00

28411: complete submodule and annex as subcommands; complete files when the subcommand is unknown.

This commit is contained in:
Clint Adams 2010-11-14 19:43:01 +00:00
parent a5f7c8d5a4
commit 7be8594c8c
2 changed files with 15 additions and 3 deletions

View file

@ -1,3 +1,9 @@
2010-11-14 Clint Adams <clint@zsh.org>
* 28411: Completion/Unix/Command/_git: complete submodule
and annex as subcommands; complete files when the subcommand
is unknown.
2010-11-10 Clint Adams <clint@zsh.org>
* 28401: Completion/Debian/Command/_git-buildpackage:
@ -13809,5 +13815,5 @@
*****************************************************
* This is used by the shell to define $ZSH_PATCHLEVEL
* $Revision: 1.5119 $
* $Revision: 1.5120 $
*****************************************************

View file

@ -205,6 +205,7 @@ _git_commands () {
'stage:add file contents to the staging area'
'stash:stash away changes to the working tree'
'status:show working-tree'\''s status'
'submodule:initialize or update or inspect submodules'
'tag:create tag object signed with GPG'
'verify-tag:check GPG signature of a tag')
@ -290,7 +291,8 @@ _git_commands () {
'cvsimport:import a CVS "repository" into a git repository'
'svnimport:import SVN repository into git'
'quiltimport:apply a quilt patchset'
'svn:bidirectional operation between a single Subversion branch and git')
'svn:bidirectional operation between a single Subversion branch and git'
'annex:manage files without tracking content')
local -a ancillary_commands
ancillary_commands=(
@ -4493,7 +4495,11 @@ if [[ $service == git ]]; then
__git_aliases_and_commands
else
curcontext="${curcontext%:*:*}:git-$words[1]:"
_call_function ret _git-$words[1]
if (( $+functions[_git-$words[1]] )); then
_call_function ret _git-$words[1]
else
_files
fi
return ret
fi
;;