Skip to content

Commit

Permalink
completion: fix branch.autosetup(merge|rebase)
Browse files Browse the repository at this point in the history
When attempting to complete

  $ git config branch.auto<TAB>

'autosetupmerge' and 'autosetuprebase' don't come up. This is because
"$cur" is matched with "branch.*" and a list of branches are
completed. Add 'autosetupmerge', 'autosetuprebase' as candidates for
completion too, using __gitcomp_nl_append ().

Signed-off-by: Ramkumar Ramachandra <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>
  • Loading branch information
artagnon authored and gitster committed Jan 6, 2014
1 parent f33c2c0 commit 422553d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions contrib/completion/git-completion.bash
Original file line number Diff line number Diff line change
Expand Up @@ -1841,6 +1841,7 @@ _git_config ()
branch.*)
local pfx="${cur%.*}." cur_="${cur#*.}"
__gitcomp_nl "$(__git_heads)" "$pfx" "$cur_" "."
__gitcomp_nl_append $'autosetupmerge\nautosetuprebase\n' "$pfx" "$cur_"
return
;;
guitool.*.*)
Expand Down

0 comments on commit 422553d

Please sign in to comment.