Re: [PATCH 2/2] completion: simplify ls-files filter

2018-03-17 Thread Junio C Hamano
SZEDER Gábor writes: > First, neither 'git ls-files' nor 'git diff-index' produce quite the > same order as the 'sort' utility does, e.g.: > > $ touch foo.c foo-zzz.c > $ git add foo* > $ git diff-index --name-only HEAD > foo-zzz.c > foo.c > $ git diff-index

Re: [PATCH 2/2] completion: simplify ls-files filter

2018-03-17 Thread SZEDER Gábor
> When filtering the ls-files output we take care not to touch absolute > paths. This is redundant, because ls-files will never output absolute > paths. Furthermore, sorting the output is also redundant, because the > output of ls-files is already sorted. > > Remove the unnecessary operations.

Re: [PATCH 2/2] completion: simplify ls-files filter

2018-03-17 Thread Junio C Hamano
Clemens Buchacher writes: > When filtering the ls-files output we take care not to touch absolute > paths. This is redundant, because ls-files will never output absolute > paths. Furthermore, sorting the output is also redundant, because the > output of ls-files is already

[PATCH 2/2] completion: simplify ls-files filter

2018-03-17 Thread Clemens Buchacher
When filtering the ls-files output we take care not to touch absolute paths. This is redundant, because ls-files will never output absolute paths. Furthermore, sorting the output is also redundant, because the output of ls-files is already sorted. Remove the unnecessary operations.