summary refs log tree commit diff
path: root/Completion/Unix/Command
diff options
context:
space:
mode:
authorClint Adams <clint@users.sourceforge.net>2010-11-14 19:43:01 +0000
committerClint Adams <clint@users.sourceforge.net>2010-11-14 19:43:01 +0000
commit7be8594c8cfea3fac39fa73cd5bcbae7e7f23477 (patch)
treea764c8c4e3729557b4e9314b6828a8205cc2498f /Completion/Unix/Command
parenta5f7c8d5a499814eedad83a60dcf90460eeeb74a (diff)
downloadzsh-7be8594c8cfea3fac39fa73cd5bcbae7e7f23477.tar.gz
zsh-7be8594c8cfea3fac39fa73cd5bcbae7e7f23477.tar.xz
zsh-7be8594c8cfea3fac39fa73cd5bcbae7e7f23477.zip
28411: complete submodule and annex as subcommands; complete files when the subcommand is unknown.
Diffstat (limited to 'Completion/Unix/Command')
-rw-r--r--Completion/Unix/Command/_git10
1 files changed, 8 insertions, 2 deletions
diff --git a/Completion/Unix/Command/_git b/Completion/Unix/Command/_git
index c394e0845..af716be85 100644
--- a/Completion/Unix/Command/_git
+++ b/Completion/Unix/Command/_git
@@ -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
       ;;