git completion: Ignore stderr for all commands

Might print unrelated crap if we try to complete while not in a git repository
This commit is contained in:
Fabian Homborg 2015-06-21 18:33:08 +02:00
parent b231ab7238
commit 00556734bc

View file

@ -6,7 +6,7 @@ function __fish_git_branches
end end
function __fish_git_tags function __fish_git_tags
command git tag command git tag ^/dev/null
end end
function __fish_git_heads function __fish_git_heads
@ -15,7 +15,7 @@ function __fish_git_heads
end end
function __fish_git_remotes function __fish_git_remotes
command git remote command git remote ^/dev/null
end end
function __fish_git_modified_files function __fish_git_modified_files
@ -89,14 +89,14 @@ end
function __fish_git_complete_stashes function __fish_git_complete_stashes
set -l IFS ':' set -l IFS ':'
command git stash list --format=%gd:%gs | while read -l name desc command git stash list --format=%gd:%gs ^/dev/null | while read -l name desc
echo $name\t$desc echo $name\t$desc
end end
end end
function __fish_git_aliases function __fish_git_aliases
set -l IFS \n set -l IFS \n
command git config -z --get-regexp '^alias\.' | while read -lz key value command git config -z --get-regexp '^alias\.' ^/dev/null | while read -lz key value
begin begin
set -l IFS "." set -l IFS "."
echo -n $key | read -l _ name echo -n $key | read -l _ name