Skip to content

Commit bd9efbf

Browse files
committed
Merge branch 'maint'
* maint: grep: pass -I (ignore binary) down to external grep
2 parents f39e4cf + 2819075 commit bd9efbf

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

builtin-grep.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,8 @@ static int external_grep(struct grep_opt *opt, const char **paths, int cached)
291291
push_arg("-E");
292292
if (opt->regflags & REG_ICASE)
293293
push_arg("-i");
294+
if (opt->binary == GREP_BINARY_NOMATCH)
295+
push_arg("-I");
294296
if (opt->word_regexp)
295297
push_arg("-w");
296298
if (opt->name_only)

0 commit comments

Comments
 (0)