← Back to context

Comment by merlinscholz

4 years ago

Any reason to use `find -type f |xargs grep -i ...` instead of `grep -i -r "whatever" .`?

I usually put a few paths in between "find" and "-type", use the other predicates of "find" and often rewrite if from a just executed `find ... | grep`.

One particular modification is to extend the pipeline between the "find" and the "xargs" to filter the file list, especially `grep -v .git` ;-)