Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
completion: fast initial completion for config 'remote.*.fetch' value
[gitweb.git]
/
contrib
/
completion
/
git-completion.bash
diff --git
a/contrib/completion/git-completion.bash
b/contrib/completion/git-completion.bash
index f992b1399d94fc5b20a475412efc855f27af2595..c76b645bedfbc20a12fbea8b2585216f8dd661d4 100755
(executable)
--- a/
contrib/completion/git-completion.bash
+++ b/
contrib/completion/git-completion.bash
@@
-1891,6
+1891,10
@@
_git_config ()
remote.*.fetch)
local remote="${prev#remote.}"
remote="${remote%.fetch}"
+ if [ -z "$cur" ]; then
+ COMPREPLY=("refs/heads/")
+ return
+ fi
__gitcomp_nl "$(__git_refs_remotes "$remote")"
return
;;