Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using Git in a TFS shop

Tags:

git

tfs

Using Git at home has spoiled me - I now find using TFS at work to be a bit of a drag and want to explore the possibility of using Git locally and syncing somehow with TFS. I figure there are a few different ways this can be done and would like to hear from people that have attempted it.

I've found a blog post that describes a relatively manual workflow, but I'm hoping for something with better automation, and history support.

Jim Deville appears to be writing a series on how the IronRuby team keeps their github repository in sync with TFS but it is not yet complete and I must admit I had a little trouble following what Jim has written so far.

I briefly attempted to use a combination of SvnBridge and git-svn but I got stuck on an error quite quickly (perhaps this one?). I do intend to explore this further...

Update: It looks like some people have had some success with the SvnBridge git-svn combo. See here.

Finally, perhaps GitSharp will make it easier to develop a useful solution to this problem? Not because GitSharp has anything to do with TFS per se, but simply because it exposes git automation to .NET developers.

Related Question - Git and Team Foundation Server

like image 583
Paul Batum Avatar asked Nov 06 '09 14:11

Paul Batum


People also ask

Can I use Git with TFS?

Git in Visual Studio, Azure DevOps Services, and TFS is standard Git. You can use Visual Studio with third-party Git services, and you can also use third-party Git clients with TFS. To learn more, see Git and Azure Repos.

How do I create a Git repository in TFS?

In the Project area in the web portal, select Code, then select the drop-down next to the current repo name and choose New Repository. In the Create a new repository dialog, verify that Git is the repo type and enter a name for your new repo.

Does TFS 2015 support Git?

In Team Foundation Server 2015 Update 1, a project administrator can add a Git repo to a project created with Team Foundation Version Control (TFVC). You can also add a TFVC repo to a project created with Git. This allows you to adopt a new version control system while preserving all the data in your project.

Should I use Git or TFS?

You should use Git for version control in your projects unless you have a specific need for centralized version control features in TFVC. In other words, if you have a very specific reason why you need to continue using TFVC, Microsoft would rather you didn't.


1 Answers

There's the open source project Git-tfs (not to be confused with Git-tf):

https://github.com/spraints/git-tfs

like image 97
Mladen Mihajlovic Avatar answered Oct 05 '22 21:10

Mladen Mihajlovic