[completions/git] Remove unnecessary helper function

This commit is contained in:
Fabian Homborg 2018-06-15 14:06:18 +02:00
parent 7b86062720
commit fa665bd3c8

View file

@ -47,12 +47,9 @@ function __fish_git_tags
command git tag --sort=-creatordate 2>/dev/null
end
function __fish_git_dir
command git rev-parse --git-dir 2>/dev/null
end
function __fish_git_heads
set -l gitdir (__fish_git_dir)
set -l gitdir (command git rev-parse --git-dir 2>/dev/null)
or return # No git dir, no need to even test.
for head in HEAD FETCH_HEAD ORIG_HEAD MERGE_HEAD
if test -f $gitdir/$head
echo $head