Can you recommend any tool to migrate sources(with history) from TFS to SVN?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Have you looked at tfs2svn?
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.
回答2:
We are migrating TFS 2010 collections into svn. To make it work for us I needed to download and modify the source of TFS2SVN so that it understood the collections we had made.
At the moment I just hard coded the values because we are only going to use this twice. We modified tfs2svn\trunk\Colyar.SourceControl.Tfs2Svn\Tfs2SvnConverter.cs as follows
public Tfs2SvnConverter(string tfsPath, string svnPath, bool createSvnFileRepository, int fromChangeset, string workingCopyPath, string svnBinFolder, bool doInitialCheckout, string tfsUsername, string tfsPassword, string tfsDomain)
{
ParsePaths(tfsPath, svnPath);
this._tfsServer = "http://<tfs domain>:8080/tfs/<team project collection name>";
this._tfsRepository = "<remote source location>"; // "$/<team project name>/..."
//this._tfsExporter = new TfsExporter(this._tfsServer, this._tfsRepository, workingCopyPath, fromChangeset, tfsUsername, tfsPassword, tfsDomain);
TfsClient.Provider.Connect(this._tfsServer, this._tfsRepository, workingCopyPath, fromChangeset, tfsUsername, tfsPassword, tfsDomain);
this._svnImporter = new SvnImporter(this._svnRepository, workingCopyPath, svnBinFolder);
_createSvnFileRepository = createSvnFileRepository;
_doInitialCheckout = doInitialCheckout;
_workingCopyPath = workingCopyPath;
HookupTfsExporterEventHandlers();
}