diff options
author | SZEDER Gábor <szeder@ira.uka.de> | 2008-03-06 22:37:36 +0100 |
---|---|---|
committer | Shawn O. Pearce <spearce@spearce.org> | 2008-03-10 19:55:07 -0400 |
commit | 51fe120903370ca8bf384c839c8cfb70ee563eb0 (patch) | |
tree | a929279e30c6fa287167e4b24537e80156ccd4b3 /contrib | |
parent | 6753f2aa55280a0fef1cbdcee71c1b529cb0c910 (diff) | |
download | git-51fe120903370ca8bf384c839c8cfb70ee563eb0.tar.gz |
bash: use __gitdir when completing 'git rebase' options
When doing completion of rebase options in a subdirectory of the work
tree during an ongoing rebase, wrong options were offered because of the
hardcoded .git/.dotest-merge path.
Signed-off-by: SZEDER Gábor <szeder@ira.uka.de>
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'contrib')
-rwxr-xr-x | contrib/completion/git-completion.bash | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash index 73ed095487..fc108e4828 100755 --- a/contrib/completion/git-completion.bash +++ b/contrib/completion/git-completion.bash @@ -841,8 +841,8 @@ _git_push () _git_rebase () { - local cur="${COMP_WORDS[COMP_CWORD]}" - if [ -d .dotest ] || [ -d .git/.dotest-merge ]; then + local cur="${COMP_WORDS[COMP_CWORD]}" dir="$(__gitdir)" + if [ -d .dotest ] || [ -d "$dir"/.dotest-merge ]; then __gitcomp "--continue --skip --abort" return fi |