bash: complete more options for 'git rebase'
authorBjörn Gustavsson <bgustavsson@gmail.com>
Sat, 17 Oct 2009 09:33:38 +0000 (11:33 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 28 Oct 2009 07:36:43 +0000 (00:36 -0700)
Complete all long options for 'git rebase' except --no-verify
(probably used very seldom) and the long options corresponding
to -v, -q, and -f.

Signed-off-by: Björn Gustavsson <bgustavsson@gmail.com>
Acked-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/completion/git-completion.bash

index d3fec329976c698d55f4873efb2826ed4471919a..7c7318c43679a95d05f4192304022cef8eb246ea 100755 (executable)
@@ -1323,8 +1323,18 @@ _git_rebase ()
        fi
        __git_complete_strategy && return
        case "$cur" in
+       --whitespace=*)
+               __gitcomp "$__git_whitespacelist" "" "${cur##--whitespace=}"
+               return
+               ;;
        --*)
-               __gitcomp "--onto --merge --strategy --interactive"
+               __gitcomp "
+                       --onto --merge --strategy --interactive
+                       --preserve-merges --stat --no-stat
+                       --committer-date-is-author-date --ignore-date
+                       --ignore-whitespace --whitespace=
+                       "
+
                return
        esac
        __gitcomp "$(__git_refs)"