Skip to content

Commit 1b96965

Browse files
committed
Merge branch 'cn/branch-set-upstream-to'
Finishing touches to the recently graduated topic to introduce "git branch --set-upstream-to" option. * cn/branch-set-upstream-to: completion: complete branch name for "branch --set-upstream-to=" completion: add --set-upstream-to and --unset-upstream
2 parents ebf91ab + ca45d0f commit 1b96965

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

contrib/completion/git-completion.bash

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -875,11 +875,15 @@ _git_branch ()
875875
done
876876

877877
case "$cur" in
878+
--set-upstream-to=*)
879+
__gitcomp "$(__git_refs)" "" "${cur##--set-upstream-to=}"
880+
;;
878881
--*)
879882
__gitcomp "
880883
--color --no-color --verbose --abbrev= --no-abbrev
881884
--track --no-track --contains --merged --no-merged
882-
--set-upstream --edit-description --list
885+
--set-upstream-to= --edit-description --list
886+
--unset-upstream
883887
"
884888
;;
885889
*)

0 commit comments

Comments
 (0)