From a1303d2c04e61582eab79765bb310b402ee2e2e2 Mon Sep 17 00:00:00 2001 From: q Date: Mon, 17 Mar 2014 19:10:12 +0200 Subject: [PATCH] added color --- qcd_function | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/qcd_function b/qcd_function index 1ef7689..be8a84c 100644 --- a/qcd_function +++ b/qcd_function @@ -215,7 +215,10 @@ function igrep () { while true do read -e -i "$args" args echo $@ - grep $args "$@" + grep --color=auto $args "$@" + if [ "$?" -ne 0 ] + then echo _no_matches_ | grep --color=auto ".*" + fi done }