Linux Blog

Remove all subversion .svn folders

Filed under: Quick Linux Tutorials,Shell Script Sundays — TheLinuxBlog.com at 2:30 am on Sunday, December 12, 2010

remove all subversion folders

This may be a no brainer for some of you elitists out there but if you need to (I don’t ask questions) remove all .svn folders within a project there is an easy way to do so. This would also work for other directories, but my main purpose for writing this is for .svn files / folders.

find . -iname ".svn" | xargs rm -r $1

I suppose you could also use svn export to get similar functionality, but if you’ve already checked out code, you wouldn’t want to waste precious internets and do it again would you?

Man Pages for commands in this post »

svn
find
xargs

3 Comments »

Comment by map007

December 20, 2010 @ 9:07 am

Hi,

Nice Article….!!!

Thanks.

Comment by Egghead123

December 21, 2010 @ 7:08 am

Great hint – Thanks

Comment by abhilash

December 21, 2010 @ 2:01 pm

good information, thanks

RSS feed for comments on this post. TrackBack URI

Leave a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>