No Free Time

Because my therapist says I need to let things out

Howto: Only include part of a project workspace in a TFS 2008 Team Build

with 2 comments

I’m working on a website with a large design aspect, so we have a lot of .psd files (about 200mb) kicking about the place. We want them source controlled, so they live in the TFS 2008 team project folder in source control. But then our Team Build includes them when downloading the source files, so that quickly fills up our build server’s drive and makes a single build take up to 11 minutes, which is far too long for a basic eCommerce website.

So I trimmed these files from our build process. Here’s what I did:

  1. Copy the .psd files and any other files that aren’t required for a build into a seperate folder in the root of the team project. (All our website/source files are in another folder called ‘Current’, as in the ‘current version’, as opposed to ‘Phase 1’, ‘Phase 2’)
  2. In Team Explorer, right click the build you want to edit and selected Edit Build Definition…
  3. In the Workspace tab, enter the path within source control where you want to start downloading files from. In our case I chose the $/[project]/Current folder, so the /PSDs folder will be ignored and not downloaded.

Now, thanks to the above steps my build history folders are 1/10th the size they were to begin with, and the build process takes less than half the time!

Written by Andrew Myhre

July 17, 2008 at 12:56 am

Posted in infrastructure

Tagged with , ,

2 Responses

Subscribe to comments with RSS.

  1. This is a good solution but you could have also used the cloak feature to exclude the specific folder from the build without having to move it around

    benoit808

    November 18, 2008 at 2:17 pm

  2. Oh, snap. I didn’t know about that feature, looks great though!

    http://msdn.microsoft.com/en-us/library/ms181378.aspx

    andrewmyhre

    November 18, 2008 at 8:56 pm


Leave a comment