2

Our client is using TFS, and we are using GitHub

I would like to sync the projects from TFS to Github and from GItHub to TFS as batch process whenever the changes are made in either of them.

Can someone suggest easiest way of doing the same?

Thanks in advance

Riya
  • 43
  • 6

2 Answers2

1

git-tfs which is a two-way bridge between TFS (Team Foundation Server) and git. However if you are using TFS2013 and later, you could use Git as the source control option. You could directly use normal git command such as git pull, git push. For the command to the get from github, just use the normal git command such as: git-scm.com/docs/git-pull

Neha
  • 197
  • 1
  • 12
0

In Azure Devops or Github, both of them use git as their Version Control, so you can have both as separate git remotes.

You could just use some git commands to handle this. Which command please take a look at this blog.

For automated process, then you could use one CI build definition to achieve it. Detail steps as below:

  • Create a CI build with a PowerShell or cmd Task;
  • Select the VSTS git repo in Get sources step;
  • Enable continuous integration andspecify include all branches for Branch filters:

Two samples for your reference:

How to synchronize VSTS and Github respositories when commits are made

Syncing my Github repo to MS Visual Studio Team Services

Besides, you could also use some 3-rd party extension to handle this, such as this one--Git Tools for Azure DevOps

Azure Pipelines Build and Release extension that helps you synchronise one Git Repository with another.

You can use this extension with any Git repository: TFS, GitHub, Azure DevOps, Git, etc.

PatrickLu-MSFT
  • 49,478
  • 5
  • 35
  • 62