I have a solution that is source controlled with Subversion and AnkhSVN in Visual Studio 2008, but I would like to remove source control from it, how do I do that?
-
1Is it a silly question to ask why you want to de-SCR your project? – annakata May 05 '09 at 09:47
-
I think I have bound it to high up the root, and now it wants to use a repository it shouldn't be using – Peter May 05 '09 at 09:58
-
1I had a similar issue where I had a really old project that was actually bound to an SVN server that no longer existed. Needed to unversion all the files so I could add it to our current SVN server. – kdmurray Mar 29 '11 at 19:51
5 Answers
SVN, as opposed to the dreaded VSS, does not clutter your project files with its "bindings": it keeps all its system information in .svn
or _svn
subfolders inside every version-controlled directory. Thus, "removing" version control from a project effectively means deleting all these folders.
This is tedious, however, so SVN has a special command called svn export which either "exports a clean directory tree from the repository specified by URL" or "exports a clean directory tree from the working copy ".

- 113,561
- 39
- 200
- 288
-
5If you were using Tortoise, you could right click on the root folder of your solution and under the Tortoise SVN sub menu, click Export to gain access to the export command. – Mark Dickinson May 05 '09 at 09:42
-
1You can also export in place, i.e. strip a working copy from its .svn folders, with svn export --force . – Wim Coenen May 05 '09 at 21:17
As far as I know, AnkhSVN stores bindings in the project and solution files (also cached in solution user options file **.suo*).
I think that you can remove these bindings by going to File | Source control | Change Source Control
(or in the dedicated AnkhSVN toolbar). In that dialog there should be a command to Disconnect
the projects.

- 217,595
- 99
- 455
- 496

- 155,851
- 29
- 291
- 343
-
2This step is optional in AnkhSVN (as registering in the solution and/or projects is optional for most project types), but you should do this if you did mark your project as managed by Subversion before. – Bert Huijben May 05 '09 at 13:15
-
1I did this, and also deleted the svn folder. Then I placed it in a Git repo and pushed it up. Now, every time I open the solution, it thinks it's still in SVN, but has no reference to where. I have to disconnect it again every time I open it, and change the Tools/Options/Source Control/Current source control plug-in to Git, which makes me a sad panda. – JRodd Aug 02 '18 at 20:51
Remove .svn folders and your source tree will not be versioned anymore.

- 30,263
- 18
- 74
- 108
-
1Not true if you have marked your project as "Managed by Subversion" in visual studio. – JFTxJ Aug 24 '12 at 14:48
-
5I had to remove the following lines from the .sln file: GlobalSection(SubversionScc) = preSolution Svn-Managed = True Manager = AnkhSVN - Subversion Support for Visual Studio EndGlobalSection – Baxter Oct 14 '14 at 20:49
- Delete SVN folder with a hidden attributes from your file system
- open VS solution file in text editor & remove a reference to subversion "...Managed by Subversion..." works fine for me..

- 11
- 1
If you want to remove the Subversion control of a file/folder, but want to leave it where it currently is, you can use the 'Delete (keep local)' option on TortoiseSVN. To see this option you must hold down shift when you right-click the file/folder, then it will appear in the context menu.

- 5,616
- 10
- 52
- 72
-
1This will not remove the administrative area in the project; it will just mark them to be deleted from sourcecontrol on the next commit. (And you can never delete the root of your working copy). – Bert Huijben May 05 '09 at 13:17