From 613739ba072deffb7c0447de02c4a5a3ce296add Mon Sep 17 00:00:00 2001 From: Aaron Gyes Date: Sat, 20 Feb 2016 10:26:50 -0800 Subject: [PATCH] Try to just see if grep is happy with --color=auto, or not, as the --help exit status varies in BSD vs. GNU. --- share/functions/grep.fish | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/share/functions/grep.fish b/share/functions/grep.fish index 73f21922d..bedf18be7 100644 --- a/share/functions/grep.fish +++ b/share/functions/grep.fish @@ -2,9 +2,8 @@ # Match colors for grep, if supported # -if command grep --color=auto --help 1>/dev/null 2>/dev/null +if echo | command grep --color=auto "" >/dev/null 2>&1 function grep command grep --color=auto $argv end end -