From 0967ef2ab886a66a30e2e0089ab74096d187169b Mon Sep 17 00:00:00 2001 From: Kyle Evans Date: Wed, 25 Apr 2018 18:59:29 +0000 Subject: [PATCH] grep: Special case the -V flag In case we need version information of the ultimately chosen grep, allowing `zgrep -V` to operate would be most helpful. --- usr.bin/grep/zgrep.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/usr.bin/grep/zgrep.sh b/usr.bin/grep/zgrep.sh index c8b91fc34a4f..347d4ee9f720 100755 --- a/usr.bin/grep/zgrep.sh +++ b/usr.bin/grep/zgrep.sh @@ -106,6 +106,10 @@ do silent=1 shift ;; + -V) + ${grep} -V + exit $? + ;; -*) grep_args="${grep_args} $1" shift