Date: Thu, 06 Dec 2001 14:39:52 -0800 From: rick norman <norm.butts@lmco.com> To: Drew Tomlinson <drew@mykitchentable.net> Cc: questions@freebsd.org Subject: Re: How to Use Find To Remove Files? Message-ID: <3C0FF3B8.116E6FBE@lmco.com> References: <000f01c17ea3$7bc9db40$962a6ba5@lc.ca.gov>
next in thread | previous in thread | raw e-mail | index | archive | help
I would use something like : find . -name "*.core" -exec rm {} \; Rick Drew Tomlinson wrote: > I'm trying to learn to use the tools as intended. :) I have a > directory tree of squirrelmail that I retrived via CVS. Because I only > need a "snapshot", I want to delete all the CVS directories in the tree. > I've used the command (find . -name "CVS" -print) from the top of the > tree and it appears to find the files I want. Heres a snip: > > blacklamb# find . -name "CVS" -print > ./CVS > ./config/CVS > ./data/CVS > ./doc/CVS > ./functions/CVS > ./help/id/CVS > ./help/ca/CVS > ./help/cs/CVS > ./help/th/CVS > ./help/en/CVS > [etc.] > > Now what I want to do is remove those files so I've tried (find . -name > "CVS" -ok "rm {}";) and various versions of the command but can't get > the syntax right. How should I construct this command? > > Thanks, > > Drew > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-questions" in the body of the message To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3C0FF3B8.116E6FBE>