From 9aa16d3b5dcfea0921ee8549e81e0d32ef791fb3 Mon Sep 17 00:00:00 2001 From: Alexander Terry Date: Thu, 16 Feb 2017 23:14:21 -0900 Subject: [PATCH] =?UTF-8?q?add=20context=20of=20=C2=B1=203=20lines=20to=20?= =?UTF-8?q?grep?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/grep.zsh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/grep.zsh b/lib/grep.zsh index abc1650a1..f2239a278 100644 --- a/lib/grep.zsh +++ b/lib/grep.zsh @@ -18,6 +18,9 @@ if grep-flag-available --exclude-dir=.cvs; then elif grep-flag-available --exclude=.cvs; then GREP_OPTIONS+=" --exclude=$VCS_FOLDERS" fi +if grep-flag-available '-C 3'; then + GREP_OPTIONS+=" -C 3" +fi # export grep settings alias grep="grep $GREP_OPTIONS"