tags:

views:

3583

answers:

3

Hi,

Is there a way to delete a folder, lets call it FolX from an SVN trunk recursively? A quick search on google only tells me how to recursively delete all .svn folders and this is not what I want to do

+7  A: 

Try something like the following on a posix system:

find ./ -name "FolX" | xargs svn delete --force

This will find all matching files/folders starting in the current directory and perform the action on them i.e. svn delete. I'm not sure how to do this in windows though without cygwin.

For win32, the commenter below suggests a similar solution:

/R . %1 in (*.EXT) do svn delete %1
Dana the Sane
I really wish there was an equivalent Windows command prompt command for this. I could install cygwin i guess.
Warren P
Found it, I wanted to recursively delete all *.EXT files from my repository, which in Win32 command (DOS) prompt terms is:for /R . %1 in (*.EXT) do svn remove %1
Warren P
Ok, I've updated the answer.
Dana the Sane
+1  A: 

svn delete FolX --force should do the trick even if there are unversioned files in the subtree.

Franci Penov
He said FolX (for ``Folder X''), not FOIX :)
ngn
+1  A: 

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

http://www.commandlinefu.com/commands/view/902/delete-all-.svn-directories-from-current-path-recursive

harshad