TFVC and Git repositories in the same team project

Jeremy Epling

Many teams are transitioning from TFVC to Git for version control and want to keep their work items, build definitions, and other data in their team project. Now with TFS Update 1 or Team Services, you can add Git repositories to your existing team project created with TFVC. In addition, you can add TFVC to an existing team project created with Git repositories.

This enables you to experiment with Git in your current team project or move all your TFVC code to Git. Teams often choose to only move the latest version of their code when they switch to Git, which is how we migrated the VSTS code from TFVC to Git. Having TFVC and Git repositories in the same team project allows you to easily access your work items, builds, and code history without switching team projects.

It’s easy to add Git to your team project:

  1. Go to the Code hub group

  2. Open the repository selector

  3. Select “New repository…”

  4. Enter the name of your new Git repository

  5. Select “Create”

You’ll be taken to the new empty Git repository page with instructions on how to add code. The new repo is in the repo selector along with your existing TFVC repository. Each repository type has its own icon so it’s easier to see which repos are TFVC or Git.

Depending on when your team project was created, you’ll need to modify version control permissions to allow access to the new repository type. This article provides details on how to update permissions, and we’ll remove the need to update permissions in more scenarios between now and Update 2.

If you use Visual Studio, Visual Studio 2015 Update 1 has support for team projects with both repo types. Just refresh the connection to your team project and the new repo type will appear. VS 2015 RTM and previous versions will only show the type of repo created with the team project.

I’m happy to deliver a top request on uservoice. More are on the way.

Jeremy Epling
VSTS / TFS Program Manager

0 comments

Discussion is closed.

Feedback usabilla icon