[thelist] find
ben morrison
morrison.ben at gmail.com
Fri Feb 27 07:17:12 CST 2009
how about using * although not sure about CASE sensitivity, probably a flag
on find maybe?
find . -name *whatever* -exec rm {} \;
you can also pipe the response and use xargs to remove
find . -name *whatever* | xargs rm
A quick search on case :
GNU find has a case-insensitive option '-iname', however
other 'finds' don't have it and we have to make do with
the [..] constructs.e.g., to search for all files ending in
.pdf/.PDF/.pDf/... etc.
find . \( -name '*.[pP][dD][fF]' -o -name '.*.[pP][dD][fF]' \) -print
Ben
On Fri, Feb 27, 2009 at 12:57 PM, Bob Meetin <bobm at dottedi.biz> wrote:
> find . -name whatever -exec rm {} \;
>
> That works to delete all files called 'whatever'. What are the wildcard
> options with find to find names like whatever as in:
>
> abc.whatever
> whatever-xyz
> def_WHATever
>
> Thx, Bob
>
> --
>
> * * Please support the community that supports you. * *
> http://evolt.org/help_support_evolt/
>
> For unsubscribe and other options, including the Tip Harvester
> and archives of thelist go to: http://lists.evolt.org
> Workers of the Web, evolt !
>
--
Ben Morrison
More information about the thelist
mailing list