How to: Branching and Merging Guide

As anyone who had experience with branching they will tell you branching is easy merging is hard. Which is why you should always ask yourself if you need to branch and only do so if you have to. Luckily, if you do need to branch there is a great guide from the ALM Rangers: Visual Studio Team Foundation Server Branching and Merging Guide.

 

The guidance starts off by trying to assess what branching and merging strategy is best suited to your team product:

image

 

I would say if you work in a small team at most you would be branching for releases (see guide for more details):

image

 

If you work in medium size team you would be branching for releases and possibly features:

image

 

If you work in a large team then you would follow a host of different branching/merging techniques.

image

 

I’ve taken a small amount to hopefully entice you go through the guidance in more detail which can be found here: Visual Studio Team Foundation Server Branching and Merging Guide. Also worth noting and reading is:

  • The Deceptive Allure of Merging with Labels – Team Foundation Server uses labels to refer not to a point in time but rather to any collection of files that have been grouped together by the user, so a branch that is created by label is often specific to the needs of an individual developer or task.
  • You should branch from main or another dev branch – not from somewhere deeper in the folder hierachy.

This post is one from a series of posts on the subject of becoming a senior developer (see initial post for more details). Please leave a comment if you found this useful or have something to add.

Advertisements