TFS Branching and Merging Guidance
Visual SourceSafe (VSS) was a good tool for code management. Almost too good in fact as development teams weren’t in a rush to migrate away from it (although anyone using VSS could easily rattle off its flaws). Is it on par with Team Foundation Server (TFS)? Of course not. The problem is that TFS appears to be more complicated but in reality it’s just as simple (from a source control perspective). Obviously having a dedicated Build Manager lessens the load on a developer who will inevitably be doing double-duty as one but it’s certainly not mandatory.
The issue that I most often hear isn't that TFS does not encompass the features that development teams want (in this case, a source code management system) but rather the complexity that is sometimes built around it. Meaning: Most teams will have at least one main/root container for their code and then build a structured code repository from it. This is where the branching and merging aspect of TFS is extremely important to understand and unfortunately most teams do not.
To shed some light on this topic there is a plethora of documentation available but I wanted to highlight a few that I believe will provide those in charge of build configurations and release management the ability to have an extremely organized TFS structure for either a simple or very complex system that's being developed.
Resources
Let’s talk about the ALM Rangers – they’re a team that delivers out of band solutions for missing features or guidance pertaining to Visual Studio. The Visual Studio TFS Branching Guide 2010 is hosted on CodePlex (sneak peek at info about v2 here) and contains just about everything you need to become a subject matter expert (SME) on branching and merging within TFS. For additional Rangers solutions and projects by version, check out their accompanying MSDN site here.
Eric Swanson who works for Sogeti USA put together a nice introduction video that not only illustrates the basics when it comes to branching and merging within TFS but also conflict resolution (i.e. multiple teams working on the same solution).
Brian Keller - Senior Technical Evangelist, has a great video on Channel9 which details some of the visualization enhancements around branching and merging. Note: Brian's using the old CTP version but the concepts are still the same.
There’s something to be said about having up to date technical documentation and MSDN doesn’t disappoint. The branching and merging section offers guidance on defining branches strategically, explains the procedures used to merge branches as well as how to track merged Changesets.
As a side note, check out the Architecture Tooling Guide as it has some great Hands-On-Labs (HOLs) dealing with real world architecture scenario’s and comes as a Visual Studio extension.
Summary
Grasping the concept of branching and merging is not a trivial task but once accomplished can lead to a development team who can be more productive (e.g. adding features while testing is being conducted) which would then ease future or if applicable service pack development.