summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Robert Fitzsimons <robfitz@273k.net>2006-06-06 23:15:16 +0000
committerLibravatar Junio C Hamano <junkio@cox.net>2006-06-06 16:22:45 -0700
commit3026402cbc60c003c4bc043368afc619e4d9b3cd (patch)
tree43a4dde385975060d98cfe71835d123fa57c0293
parentHTTP cleanup (diff)
downloadtgif-3026402cbc60c003c4bc043368afc619e4d9b3cd.tar.xz
builtin-grep: pass ignore case option to external grep
Don't just read the --ignore-case/-i option, pass the flag on to the external grep program. Signed-off-by: Robert Fitzsimons <robfitz@273k.net> Signed-off-by: Junio C Hamano <junkio@cox.net>
-rw-r--r--builtin-grep.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/builtin-grep.c b/builtin-grep.c
index acc4eea363..5fac5701e6 100644
--- a/builtin-grep.c
+++ b/builtin-grep.c
@@ -459,6 +459,8 @@ static int external_grep(struct grep_opt *opt, const char **paths, int cached)
push_arg("-n");
if (opt->regflags & REG_EXTENDED)
push_arg("-E");
+ if (opt->regflags & REG_ICASE)
+ push_arg("-i");
if (opt->word_regexp)
push_arg("-w");
if (opt->name_only)