View Tutorial Metadata Edit Content Revision History Add to Watchlist Add New Tutorial How to remove .svn folders

How to remove .svn folders

Why do this?

Simple, sometimes the SVN server, because of wrong file permissions, just errors out completely and you need a quick way to delete all the folders it created.

I'm sure you don't want to do remove all the ".svn" folders manually so read the solutions below, based on your Operating System :

Linux

You need to run this command in the folder you want the .svn entries cleared.

find . -name ".svn" -type d -exec rm -rf {} ;

What it does is basically ... search in the current folder and all its subfolders for all folders called ".svn" and remove them.

Windows XP/Vista/7/Other versions

Open Notepad and copy & paste the line below in it :

FOR /F “tokens=*” %%G IN (DIR /B /AD /S *.svn*’) DO RMDIR /S /Q %%G

then save the file with this name "clear_svn.bat", put it in the folder you want the .svn entries cleared and double click it. That's all.

Only plain text supported.

Optional

Required - will be kept private

Optional

 
 

Rating: (0+, 0-) In: Windows XP, Windows Vista, Windows 7, Linux, Source Code Management, Subversion