0
votes

I am newbie to GitHub. We are currently using TFS 2013 for source control. We have 3 main solutions that gets build together using .proj file and targets. In TFS the build definition is configured to use .proj file and MSBuild also uses “DefaultTemplate.xaml” Now we are migrating our code from TFS to Git source control. So we are going to migrate http://tfs:8080/MyCollection/MyTeamProject/Folder1/MainBranch to GitHub repository The .proj file is under “MainBranch” so it will get migrated, however “DefaultTemplate.xaml” is under http://tfs:8080/MyCollection/MyTeamProject/BuldProcessTemplates

Question
1> Now we have to build solution via Git, Do I need to use “DefaultTemplate.xaml”? if yes how? 2> also how do i build .proj using MSbuild in Git?

2

2 Answers

3
votes

The XAML file contains the workflow for your build. Building a .NET Visual Studio solution will always use the project/solution file and MSBuild.

Getting the sources is a different story. As you've already learned, TFVC uses another structure then Git.

This is why you don't use the DefaultTemplate.xaml but instead use something like GitTemplate.12.xaml. A lot of the steps are similar, except that this template knows how to get source code from a Git repository.

See Use the Default Template for your build process for a detailed explanation.

0
votes

You'll need to have all the files you need to build in the same git branch. Basically you change from a /MySolution/MyProject/Branch/ approach to a /Branch/MySolution/MyProject/ one.

I recommend that you create a "BuildProcessTemplates" directory with all your build files in your source control root folder.

Btw, MsBuild usually uses xml file (usually with extension .proj or .csproj/.vbproj) to describe the build process. I don't really understand what's the meaning of your .xaml file (except as a standard source code file).