[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: bash script question



Ken Irving:
> 
> If you want to remove the .svn/ directories and everything within them, something
> like this should work (remove the 'echo' if the output looks ok):
> 
>   $ cd starting/directory
>   $ find . -type d -name .svn -exec echo rm -r {} \;

GNU find also accepts the parameter (or better: operation) -detele so
you don't have to start an rm process for each file or deal with xargs.
That means you can just do (untested):

$ find . -type d -name .svn -delete

J.
-- 
I worry about people thinking I have lost direction.
[Agree]   [Disagree]
                 <http://www.slowlydownward.com/NODATA/data_enter2.html>

Attachment: signature.asc
Description: Digital signature


Reply to: