Skip to content

Commit

Permalink
Only load .exe suffix'd completions on Cygwin.
Browse files Browse the repository at this point in the history
The only platform which actually needs to define .exe suffixes as
part of its completion set is Cygwin.  So don't define them on any
other platform.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
  • Loading branch information
Shawn O. Pearce authored and Junio C Hamano committed Nov 5, 2006
1 parent 144d33d commit 76c3eb5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions contrib/completion/git-completion.bash
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,7 @@ complete -o default -o nospace -F _git_log git-whatchanged
# when the user has tab-completed the executable name and consequently
# included the '.exe' suffix.
#
if [ Cygwin = "$(uname -o 2>/dev/null)" ]; then
complete -o default -o nospace -F _git git.exe
complete -o default -F _git_branch git-branch.exe
complete -o default -o nospace -F _git_cat_file git-cat-file.exe
Expand All @@ -361,3 +362,4 @@ complete -o default -F _git_merge_base git-merge-base.exe
complete -o default -o nospace -F _git_push git-push.exe
complete -o default -o nospace -F _git_log git-show-branch.exe
complete -o default -o nospace -F _git_log git-whatchanged.exe
fi

0 comments on commit 76c3eb5

Please sign in to comment.