[ale] find or locate text
Michael D. Hirsch
mhirsch at nubridges.com
Wed Oct 9 13:52:24 EDT 2002
On Wednesday 09 October 2002 01:35 pm, Fletch wrote:
> >>>>> "Michael" == Michael D Hirsch <mhirsch at nubridges.com> writes:
>
> [...]
>
> >> That'll start up a grep for each file. More efficient to use
> >> xargs instead which will break the arguments up into batches.
> >> That find invocation will also look at things such as
> >> directories and device files as well as plain vanilla files;
> >> better to limit with `-type f' rather than `-name \*'.
> >>
> >> find . -type f -print0 | xargs --null grep fooble
>
> Michael> Why not use recusive grep: grep -r fooble *
>
> Because that'd depend on having a GNU grep (not like -print0
> and xargs --null aren't GNUisms already, and this is a Linux list
> anyhow . . . :),
True. Of course, he did state that he was using Redhat which does have
gnu grep.
--Michael
---
This message has been sent through the ALE general discussion list.
See http://www.ale.org/mailing-lists.shtml for more info. Problems should be
sent to listmaster at ale dot org.
More information about the Ale
mailing list