flow.
"Flow is a condition of deep, nearly meditative involvement." - Tom DeMarco

Converting a Team Foundation Project to Subversion

Friday, August 31, 2007 9:22 AM
In the coming months we will be taking over a decently sized codebase (~ 400 KLOC) from another team.  This team is currently doing all development inside of Team Foundation server, but we do not wish to continue this trend.  We use Subversion in house and, as such, this new project will be living happily in our Subversion repository.

So here's my question to you...does anyone know how to migrate a Team Foundation repository into a Subversion repository?  The worst case scenario is that we always have the option to simply get the latest version of the code from Team Foundation, check it into Subversion, and just go from there.  The disadvantage here is that we'll be "forgetting the past" so to speak which, to be honest, doesn't really bother me as much as it probably should.  However, I would prefer to be able migrate all of the history into Subversion if at all possible.

Does anyone know of a way to do this?  Here are a few options we've talked about so far...
  • Find a tool, commercial or FOSS, that will simply convert the Team Foundation database into a Subversion database.  Although this would by far be the cleanest solution, I'm assuming that the Team Foundation database is proprietary (?) so no such tool would exist.
  • Write a script that will start at the beginning of our Team Foundation history and simply check out each version, check that version into Subversion, and rinse and repeat until up to date.  I've tried this before going from Source Safe to Subversion and although it can work it's generally very fragile, slow, and not incredibly reliable.
  • Convert Team Foundation back into Source Safe, and then convert from Source Safe to Subversion.  This would definitely be an option, I'm guess that there's no way to export a Team Foundation database into Source Safe.
We also have the option of keeping our Team Foundation history on a single machine running Team Foundation simply to make the history available to us if we need it, but I'd really like to avoid that if at all possible for obvious reasons.

Has anyone had any experience with this or have any suggestions how to proceed?  Any help would be greatly appreciated.

Feedback

 re: Converting a Team Foundation Project to Subversion

Sorry, I have no clue on how to import tfs into svn. But I'd like to know why you want to do it? What kind of problems did you run into in the past, which were solved by the svn history? 9/1/2007 4:52 PM | Thomas Eyde

# re: Converting a Team Foundation Project to Subversion

Thomas,

Good question, actually I've never had to go back very far enough in history to solve a problem (maybe I've just been lucky in that sense). And honestly, when we take this code over it'll be a clean break in the product life cycle, a brand new team, and honestly no real reason to expect that we would ever have to make an incremental roll back to see anything in history from a team that we really didn't even know.

So the more that I think about it, the more I think that we'll really don't need this...and if psychologically it would even be better if we didn't. That way the team could feel like we have a completely fresh start and aren't tied to the decisions of the past. 9/1/2007 5:34 PM | Jeremy Jarrell

 re: Converting a Team Foundation Project to Subversion

Just wondering. What are you moving off TFS Version Control? In the spirit of open disclosure, I work for Microsoft on the TFS team, and am interested in why our product would not meet your needs. (Honest, no sales-job here, just interested)
Thanks. 9/3/2007 7:37 PM | Gregg Boer

# re: Converting a Team Foundation Project to Subversion

Hi Gregg,

That's a very fair question. Essentially we've just found Team Foundation overkill for what we need. We're using it on the aforementioned project and although it has a lot of nice features it doesn't really include anything that we use. We already use an existing bug tracking system (MantisBT) that integrates with SVN plus most of the tools that I know and like to use on a project seem to work best with Subversion (CruiseControl.NET, FishEye, Crucible). I'm not saying that some of these tools won't work with TFS (I know that CruiseControl.NET has some support for it), just that I'm already familiar with using them with SVN so I'm more interested in getting simply getting the environment up and starting coding. It's very possible that TFS may provide a better source control experience than SVN, it's just until I feel like I'm missing out on something I probably won't take the time to learn another environment just to switch. So I suppose that 3rd party tool support is a big reason.

The other reason is reliability. I've lost code in TFS several times in the past few months thus far. Granted, its not near as bad as SourceSafe was but each time I lose code its very frustrating. Essentially I'll check something in, update the next day and my changes will be gone. I've also had the opposite effect where I'll have to use the update the command several consecutive times before the most recent code is actually downloaded. Also, on an unrelated note the way merging is handled (specifically the way it is checked in after merging) is a bit confusing.

Honestly, these may not be flaws in TFS but actually mistakes that my devs are making in using it. However if that is the case ease of use is still important to me. I don't mind someone having to learn a tool, but I've never had these problems with SVN which tells me that it may be a bit easier to use. So effectively, I'd say the biggest reason I'm moving off of it is reliability. Every feature in the world isn't worthwhile if I can't trust my code inside of it.

This is also unrelated, but I had one of the projects on CodePlex that was lost when one of the servers went down. I was having trouble with TFS before hand (it would never check in a deployment project that I had) but honestly the way the server crash was handled really left a bad taste in my mouth in regards to TFS.

I understand that this is a new project and I really do hope this helps. If you have any other questions, please feel free to ask.

Thanks!
Jeremy 9/5/2007 2:04 PM | Jeremy

 re: Converting a Team Foundation Project to Subversion

Thanks very much for giving such a detailed response. I understand all your points and they are good ones. I wish you the best in your conversion to SVN, and hope we can win you back in the future!
In the meantime, I'm going to make sure this information gets forward to my coworkers on the team.
Thanks again Jeremy,
Gregg 9/11/2007 8:32 PM | Gregg Boer

# re: Converting a Team Foundation Project to Subversion

Please contact me at the e-mail provided in this post. I'd like to understand the reliability problems better so we can address them. Thanks. 9/12/2007 9:10 AM | Ed Hintz

# re: Converting a Team Foundation Project to Subversion

Just tripped across this post while looking for a TFS to SVN converter myself - were you successful in coming up with a way of migrating from TFS to SVN, other than just checking in the latest version of the source?

For multiple reasons we're looking to make the same transition and I was hoping to shave a bit of time off the process by learning from someone who had been down this path already. Thanks! 11/30/2007 10:29 AM | Tony Goggin

# re: Converting a Team Foundation Project to Subversion

Hey Tony,

We actually never came up with a solution either and are actually still on TFS for the time being due to some external issues. Whenever we do convert, we'll likely just grab the latest version of the source from TFS and load it into subversion and just leave our history behind (we'll be doing this on a milestone).

Hope this helps,
Jeremy 12/1/2007 10:36 AM | Jeremy

 re: Converting a Team Foundation Project to Subversion

One of our programmers is making a tool to transition from TFS to Subversion. He has made it available on SourceForge. It is in its early stages, but it is working for a basic transition.

http://sourceforge.net/projects/tfs2svn/
1/16/2008 11:19 PM | Brian

# re: Converting a Team Foundation Project to Subversion

Thanks for the info! I'll definitely keep an eye on it. We're planning on converting in Q3 of this year so hopefully that should give him some time to make some good progress.

Thanks!
Jeremy 1/17/2008 4:53 PM | Jeremy

# re: Converting a Team Foundation Project to Subversion

One of your options would be to implement a SVN provider for the TFS Migration and Synchronisation toolkit.

http://www.codeplex.com/MigrationSyncToolkit

Then you would be able to keep SVN & TFS in-sync, or just do a one-time convert. 1/28/2008 1:47 AM | Grant Holliday

# re: Converting a Team Foundation Project to Subversion

Thanks Grant! I'll take a look at it this afternoon.

Jeremy 1/28/2008 9:28 AM | Jeremy

 re: Converting a Team Foundation Project to Subversion

Any joy on the MigrationSyncToolkit? would be very useful for my team.

Kiall 5/2/2008 1:40 PM | Kiall

# re: Converting a Team Foundation Project to Subversion

Hi Kiall,

I actually never got around to trying it. Shortly after this post, I discovered that the aggressive feature branching we had been recommended to do was actually destroying our history anyway...so there's nothing to import.

When the time comes, we'll simply take the latest commit for the TFS repository and commit it fresh to the SVN repository.

Good luck to you!
Jeremy 5/2/2008 1:55 PM | Jeremy

# re: Converting a Team Foundation Project to Subversion

tfs2svn 1.0 has been released at Sourceforge
<br/>
http://sourceforge.net/projects/tfs2svn/
<br/>
tfs2svn is a Windows application that converts a Team Foundation Server (TFS) repository into a Subversion (SVN) repository, preserving the history, branches, and commit information.

Let me know if you have any questions.
9/24/2008 12:14 PM | Kevin Colyar

 re: Converting a Team Foundation Project to Subversion

Has anyone tried the tfs2svn project? We're getting ready to migrate to SVN from TFS. 10/24/2008 11:06 AM | Chris

Post a comment





 

Please add 8 and 7 and type the answer here: