Jaa


How patterns and practices Does Source Control with Team Foundation Server (TFS)

We've used TFS for more than a year, so it's interesting to see what we're doing in practice.  If you looked at our source control, you'd see something like the following:

+ Project X version 1
+ Project X version 2
- Project Y
    |----Branches
    |----Releases
    |----Spikes
    |----TeamStuff
    |----Trunk
        |----Build
        |----Docs
        |----Keys
        |----Source
        |----Tools

While there's some variations across projects, the main practices are:

  • Major versions get their own team project (Project X version 1, Project X version 2 ...)
  • The "Trunk" folder contains the main source tree.
  • Spikes go in a separate "Spikes" folder -- not for shipping, but are kept with the project.
  • QFEs use "Branches".  Branches are effectively self-contained snapshots of code.
  • Bug fixes go in the main "Source" under the "Trunk" folder
  • If we're shipping a CTP (Customer Tech Preview) next week, but we have a good build for this week.  We create a "shelveset" for the CTP.  
  • Within each release we have a number of Customer Tech Preview (CTP) releases, we "Label" those within the structure so we can go back and find at any point in time

I'll be taking a look at how customers and different groups in Microsoft have been using TFs for Source Control.  If you have some practices you'd like to share, I'd like to hear them.  Comment here or send mail to VSGuide@microsoft.com

Comments

  • Anonymous
    January 31, 2007
    I must be on a little patterns & practices benge right now now as this is my third post in the past

  • Anonymous
    February 01, 2007
    I always tell folks one of the few places I'd probably be really hearily enticed to work within Microsoft...

  • Anonymous
    February 01, 2007
    In the past I've used the following source control structure: $Root

  • Project X
  • Project Y  - Project Z     |----Source           +  1.0.0           +  2.0.0           |-- 3.0.0              |-- Builds                 |-- Debug                 |-- Release              |-- Root Namespace                 |-- Base                    |-- BizSvcs                    |-- ClientSvcs                    |-- Common                    |-- DataSvcs                    |-- Win or Web                    |-- RefAssemblies Just another idea...
  • Anonymous
    February 05, 2007
    The comment has been removed

  • Anonymous
    February 05, 2007
    We're in the process of converting a large SaaS web application to TFS, and we're a bit overwhelmed at the lack of direction or guidance.  I'd love to see any examples of TFS source control structures for large web applications.  I'd also like to see suggested practices for shared code, such as any common, business, or data tier projects used by multiple web/win projects.  I've yet to find any guidance for shared code, yet n-tier architecture is all about shared code.  I'd think there would be a lot of detailed, real-world examples on how to work in this type of environment. We have incremental releases, so multiple team projects per "release" doesn't sound advisable in our situation.  We want to use Scrum and have each incremental release (sprint) carve some work items out of our massive backlog of features to be implemented.  Basically, I'd like to see a solid example of any "best-practice" web application with a reusable layer or two mapped into a fully-working TFS source control structure.

  • Anonymous
    March 07, 2007
    Is it approriate ( or even possible ) to use shelvesets as a sort of promotion branch?  That is have a main build that builds trunk ( or a branch ) and then have another build that builds that trunk ( or branch ) including proposed solutions ( shelvesets ).  Then when they are unit tested and approved they just get unshelved and committed to the main trunk ( or branch ).

  • Anonymous
    March 25, 2007
     Revolving credit tends to be the most prevalent among Americans

  • Anonymous
    October 08, 2007
    Could you please expand on the Branches and Releases folders? I would like to see what their sub-folders look like and how you name them. Thanks.