From: Junio C Hamano Date: Sun, 9 Mar 2008 04:10:05 +0000 (-0800) Subject: Merge branch 'jc/am' X-Git-Tag: v1.5.5-rc0~46 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/dabc42c7134596092bf59adb83c79b09f729c290?ds=inline;hp=-c Merge branch 'jc/am' * jc/am: am: --rebasing am: remove support for -d .dotest am: read from the right mailbox when started from a subdirectory --- dabc42c7134596092bf59adb83c79b09f729c290 diff --combined contrib/completion/git-completion.bash index 49e6df0965,5ae87998e6..848c067b57 --- a/contrib/completion/git-completion.bash +++ b/contrib/completion/git-completion.bash @@@ -70,7 -70,15 +70,15 @@@ __git_ps1 ( local b if [ -d "$g/../.dotest" ] then - r="|AM/REBASE" + if test -f "$g/../.dotest/rebasing" + then + r="|REBASE" + elif test -f "$g/../.dotest/applying" + then + r="|AM" + else + r="|AM/REBASE" + fi b="$(git symbolic-ref HEAD 2>/dev/null)" elif [ -f "$g/.dotest-merge/interactive" ] then @@@ -506,33 -514,7 +514,33 @@@ _git_bisect ( _git_branch () { - __gitcomp "$(__git_refs)" + local i c=1 only_local_ref="n" has_r="n" + + while [ $c -lt $COMP_CWORD ]; do + i="${COMP_WORDS[c]}" + case "$i" in + -d|-m) only_local_ref="y" ;; + -r) has_r="y" ;; + esac + c=$((++c)) + done + + case "${COMP_WORDS[COMP_CWORD]}" in + --*=*) COMPREPLY=() ;; + --*) + __gitcomp " + --color --no-color --verbose --abbrev= --no-abbrev + --track --no-track + " + ;; + *) + if [ $only_local_ref = "y" -a $has_r = "n" ]; then + __gitcomp "$(__git_heads)" + else + __gitcomp "$(__git_refs)" + fi + ;; + esac } _git_bundle ()