summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
Diffstat (limited to 'contrib')
-rw-r--r--contrib/completion/git-completion.bash8
1 files changed, 6 insertions, 2 deletions
diff --git a/contrib/completion/git-completion.bash b/contrib/completion/git-completion.bash
index a71db47d09..1cd019d2e9 100644
--- a/contrib/completion/git-completion.bash
+++ b/contrib/completion/git-completion.bash
@@ -458,8 +458,12 @@ __git_index_files ()
__git_ls_files_helper "$root" "$1" "$match" |
awk -F / '{
- print $1
- }' | sort | uniq
+ paths[$1] = 1
+ }
+ END {
+ for (p in paths)
+ print p
+ }'
}
# __git_complete_index_file requires 1 argument: