I often have the need to distribute Visual Studio source code to external parties. Internally this source code is under source control in Team Foundation Server (TFS).
It would be nice if you could just take a copy of the source files and remove the source control binding (in Visual Studio). Unfortunately I haven’t found a way to be able to do this. Even when Visual Studio says that all bindings have been removed, if you try to open up the solution you get an error message along the lines “The solution you are opening is bound to source control on the following Team Foundation Server …”
Under earlier versions of Visual Studio I had used Visual Source Safe for source control and had used a utility called VSSBindingRemover which did the job quite effectively. It removed all source control files with the solution and project directories and modified the solution and project files themselves to remove source binding information.
The process for removing bindings is simple:
- Ensure you don’t have the solution/projects open in Visual Studio
- Copy your solution to a new directory (because the tool does modify files)
- Run the utility from the command line: VSUnbindSourceControl.exe d:\mysolution folder
Once the tool is finished, all the source control bindings have been removed from any solution and project files.