Skip to content

Commit 1c11fd2

Browse files
committed
! find-in-jars: use grep -c option reduce output
1 parent 655ed4b commit 1c11fd2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/find-in-jars

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ __outputResultOfJarFile() {
314314
# - https://stackoverflow.com/questions/19120263/why-exit-code-141-with-grep-q
315315
# - https://unix.stackexchange.com/questions/305547/broken-pipe-when-grepping-output-but-only-with-i-flag
316316
# - http://www.pixelbeat.org/programming/sigpipe_handling.html
317-
if grep $regex_mode ${ignore_case_option:-} -- "$pattern" &>/dev/null; then
317+
if grep $regex_mode ${ignore_case_option:-} -c -- "$pattern" &>/dev/null; then
318318
matched=true
319319
fi
320320

0 commit comments

Comments
 (0)