Skip to content

Commit

Permalink
completions/git: Also don't use files for porcelain=2
Browse files Browse the repository at this point in the history
This was an oversight from the previous commit. Not that it matters
much, because we already removed $files.

Still, this would fail if someone defined a global $files, so let's fix it.

[ci skip]
  • Loading branch information
faho committed Jan 13, 2019
1 parent 787f453 commit 6d11e46
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion share/completions/git.fish
Expand Up @@ -157,7 +157,7 @@ function __fish_git_files
set -l ver (command git --version | string replace -rf 'git version (\d+)\.(\d+)\.?.*' '$1\n$2')
# Version >= 2.11.* has the v2 format.
if test "$ver[1]" -gt 2 2>/dev/null; or test "$ver[1]" -eq 2 -a "$ver[2]" -ge 11 2>/dev/null
command git $git_opt status --porcelain=2 $status_opt -- $files \
command git $git_opt status --porcelain=2 $status_opt \
| while read -la -d ' ' line
set -l file
set -l desc
Expand Down

0 comments on commit 6d11e46

Please sign in to comment.