John R. McPherson
Tue Apr 20 21:09:39 NZST 2004
On Tue, Apr 20, 2004 at 09:05:28PM +1200, Glenn Ramsey wrote:
> How do I find files having either of several extensions?
> Eg this finds all .c and .h files
> $find . -name '*.[ch]'
> but what if I want to find all .cpp and .h files?
> I guess I need a grouping operator in the pattern but I can't figure out
> what it is.
Use "-o" for "or":
find . -name \*.cpp -o -name \*.h
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 189 bytes
Desc: not available
More information about the wlug
NOTICE: This is an archive of a public mailing list. The University of Waikato is not responsible for its contents.