Merge branch 'sg/completion-gitcomp-nl-for-refs'
authorJunio C Hamano <gitster@pobox.com>
Thu, 26 Mar 2015 18:57:13 +0000 (11:57 -0700)
committerJunio C Hamano <gitster@pobox.com>
Thu, 26 Mar 2015 18:57:13 +0000 (11:57 -0700)
Code clean-up.

* sg/completion-gitcomp-nl-for-refs:
completion: use __gitcomp_nl() for completing refs

contrib/completion/git-completion.bash
index 931eac29ad73e84abaf87bf1d7a39f56b9a25b34..fbe597232c11c05c1b8f9c366232d52f050b8d51 100644 (file)
@@ -977,7 +977,7 @@ _git_branch ()
 
        case "$cur" in
        --set-upstream-to=*)
-               __gitcomp "$(__git_refs)" "" "${cur##--set-upstream-to=}"
+               __gitcomp_nl "$(__git_refs)" "" "${cur##--set-upstream-to=}"
                ;;
        --*)
                __gitcomp "
@@ -1045,7 +1045,7 @@ _git_checkout ()
 
 _git_cherry ()
 {
-       __gitcomp "$(__git_refs)"
+       __gitcomp_nl "$(__git_refs)"
 }
 
 _git_cherry_pick ()