[lug] Removing hidden directory recursively

Hugh Brown hugh at math.byu.edu
Fri Apr 21 14:58:49 MDT 2006


Also cd to the parent dir of the web directory before executing it (the .
in find .)

Hugh

On Fri, 21 Apr 2006, Hugh Brown wrote:

>
> find . -type d -name .svn -exec echo {} \;
>
> to make sure you aren't getting something you didn't intend and then
>
> find . -type d -name .svn -exec rm -rf {} \;
>
> depending on how many there are you can also use:
>
> find . -type d -name .svn -print0 |xargs -0 rm -rf
>
> Hugh
>
> On Fri, 21 Apr 2006, Paul Nowosielski wrote:
>
> > Dear All,
> >
> > I'm trying to remove 1000's of .svn files from a web directory.
> > Can any one give me a tip on how to do this with a one line command?
> >
> > Best,
> >
> > --
> > Paul Nowosielski
> >



More information about the LUG mailing list