completion: fix remote.pushdefault
When attempting to complete $ git config remote.push<TAB> 'pushdefault' doesn't come up. This is because "$cur" is matched with "remote.*" and a list of remotes are completed. Add 'pushdefault' as a candidate for completion too, using __gitcomp_nl_append (). Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Ramkumar Ramachandra committed
Jan 5, 2014 at 15:48 UTC
c39a2f117853d89f0aee5b616c52df46a30b108b
1 file changed
+1
contrib/completion/git-completion.bash
+1
@@ -1884,6 +1884,7 @@ _git_config ()
1884
remote.*)
1885
local pfx="${cur%.*}." cur_="${cur#*.}"
1886
__gitcomp_nl "$(__git_remotes)" "$pfx" "$cur_" "."
1887
+ __gitcomp_nl_append "pushdefault" "$pfx" "$cur_"
1888
return
1889
;;
1890
url.*.*)