Last Tuesday I was going through all tasks that we have open related to TFS Msscci provider, tfpt bind and bindings in general. One of the gems ;) I found was automating the process to bind existing solution to source control.
The story goes as follows: user is migrating source code to tfs. He can use VSSConverter or he can just copy sources to a workspace, run “tf add” and then “tf checkin”. The problem he still has, is that when he opens migrated solution in VS, it is not recognized as source controlled. The things it’s still lacking are “bindings” – pieces of information in sln and proj files, that indicate that this solution is in fact source controlled.
If the solution was bound to VSS before, then the problem may be fixed already for him, because latest VssConverter will fix bindings for you. If not, you can run “tfpt bind” which will definitely do it.
If solution was not bound at all (e.g. you were using CVS or SVN), then the solution is not that trivial. Although we don’t have a tool that would fix this situation yet, I will provide you information that can simplify the process a lot.
The possible solutions (afaik) are as follow:
I feel that approach #2 is the simplest and safest one. You can automate it a little by running “devenv solution.sln /command file.tfsAddSolutionToSourceControl” which will open the solution and execute the command. I feel that opening the solutions after the migration is a good idea anyway, just to do a quick sanity testing.