Geeks With Blogs

@jakobehn

News

Microsoft Community Contributor Award 2011


Jakob Ehn Visual Studio ALM MVP @Inmeta Crayon Visual Studio 2010
Managing Build Templates with Community TFS Build Manager
A year ago I blogged about how to manage your build process templates using the TFS API. The main reason for doing this is that you can (and should!) store your “golden” build process templates in a common location in your TFS project collection, and then add them to each team project that requires those templates. This way, you can fix a bug or add a new feature in one place and have the change affect all build definitions. However, by having the build process templates in a single location, the ......

Posted On Tuesday, February 21, 2012 2:02 PM

Handling Warnings and Errors with InvokeProcess in TFS 2010 Build
The InvokeProcess activity is very useful when it comes to running shell commands and external command line tools during a build process. When it comes to integrating with TFS source control during a build, the TF.exe command line tool can be your friend, as it lets you do most of the usual stuff such as check-in, checkout, add, modify workspaces etc. However, it can be a bit tricky to handle the output from tf.exe, since it often produces warnings that is not necessarily a problem for your build. ......

Posted On Wednesday, February 1, 2012 8:55 PM

Avoiding TF237124 when Creating Work Items in New Areas
At my company we write a lot of tools and extensions that uses the TFS API to automate various things for us. A very common thing to automate is the creation of work items and the areas and iterations structure. Creating a work item using the TFS API is simple, just connect to TFS, get the WorkItemStore service object and create a new work item and set any fields that you want to: Creating a work item //Connect to TFS and get the WorkItemStore object var tfs = new TfsTeamProjectCollection(new Uri("http://localhost:8080/... ......

Posted On Friday, January 20, 2012 9:42 AM

Introducing: Community TFS Build Manager
The latest release of the Community TFS Build Extensions include a brand new tool called Community TFS Build Manager and has been created for two reasons: An implementation of the Team Foundation Build API which is referenced by the Rangers Build Customization Guidance V2 (available H1 2012) Provide a solution to a real problem. The Community TFS Build Manager is intended to ease the management of builds in medium to large Team Foundation Server environments, though it does provide a few features ......

Posted On Friday, December 30, 2011 12:36 PM

December 2011 TFS Power Tools Release
Brian Harry just posted an update on the latest version of the TFS 2010 Power Tools. This will most likely by the last version of the Power Tools for the TFS 2010 version, next version will target Dev11! The main improvements in this release are: Team Foundation Server Power Tools for Eclipse MSSCCI Provider for 64-bit IDE’s VS 2010 Power Tools update Improved Work item Search Best Practice Analyzer now also analyzes the integration with Project Server, if you are using it Check out the early Christmas ......

Posted On Friday, December 16, 2011 5:07 PM

TF237165: Team Foundation could not update the work item because of a validation error on the server.
I often use the VS 2010/TFS 2010 evaluation virtual machines that Microsoft publishes every 6 months with the latest bits. It’s a great timesaver to use an image where everything is already setup and also contains a bit of sample data that is useful when you want to demo something for customers. There is one thing that has always been a, albeit small, but still very annoying problem and that is that the builds always partially fail when you start using the image. When you want to demo the powerful ......

Posted On Monday, December 12, 2011 5:21 PM

Compatibility Problem with Microsoft Test Manager 2010 and Visual Studio 2011
UPDATE 10.01.2012: The issue has been resolved by Microsoft and will be addressed in patch soon. Here is the full description from the Connect site: “We've identified the rootcause. This bug was introduced in the compatibility GDR patch released for VS 2010 to work against 2011 TFS Server. We shall be releasing a patch soon. Till then, please follow the workaround mentioned to unblock yourselves. “ When setting up a physical environment for a new test controller on our TFS 2010 server, I ran into ......

Posted On Friday, December 9, 2011 11:38 AM

TFS 2010 Build - Troubleshooting the TF215097 error
Anyone working with developing custom activities in TFS 2010 Build has run into the following dreadful error message when running the build: TF215097: An error occurred while initializing a build for build definition \TeamProject\MyBuildDefinit... Cannot create unknown type '{clr-namespace:[namespace]... What the error means is that when the TFS build service loads the build process template XAML for the build definition, it can’t create an instance of the customer workflow ......

Posted On Thursday, December 8, 2011 8:51 PM

First stable release of the Community TFS 2010 Build Extensions
Today the first stable release of the Community TFS 2010 Build Extensions shipped on the CodePlex site. Visual Studio ALM MVP Mike Fourie (aka Mr MSBuild Extension Pack) has been the leader of this project and has done a tremendous job, both in contributing functionality as well as coordinating the work for the first release. Great work Mike! I (as well as several others) have contributed a small part of the activities, I plan to be working on the upcoming releases as well. The build extensions contain ......

Posted On Monday, July 4, 2011 10:50 PM

Automatically Merging Work Items in TFS 2013
** Source available at http://mergeworkitems.codep... ** Half a year ago I wrote about about Merging Work Items with a custom check-in policy. The policy evaluated the pending changes and for all pending merges, it traversed the merge history to find the associated work items and let the user add them to the current changeset. I promised to post the source to the check-in policy (and I’ve got a lot of requests for it), but I never did. This was primary for two reasons: The technical solution ......

Posted On Tuesday, May 17, 2011 8:43 PM

TFS 2010 Inmeta Build Explorer
This weekend we at Inmeta release a free Visual Studio 2010 Team Explorer extensions that solves the problem with the Builds node in the Team Explorer not being hierarchic. For some reason, this part of the Team Explorer didn’t get the nice hierarchical folder structure that the Work items node got in 2010. The result is that, for a company that has several hundreds of builds in the same team project, it becomes very hard to navigate. The solution that we implemented is very simple and uses a naming ......

Posted On Monday, April 4, 2011 9:38 AM

Integrating Code Metrics in TFS 2010 Build
The build process template and custom activity described in this post is available here: http://cid-ee034c9f620cd58d... Running code metrics has been available since VS 2008, but only from inside the IDE. Yesterday Microsoft finally released Visual Studio Code Metrics Power Tool 10.0, a command line tool that lets you run code metrics on your applications. This means that it is now possible to perform code metrics analysis on the ......

Posted On Sunday, January 30, 2011 8:39 PM

TFS 2010 Build Custom Activity for Merging Assemblies
*** The sample build process template discussed in this post is available for download from here: http://cid-ee034c9f620cd58d... *** In my previous post I talked about library builds that we use to build and replicate dependencies between applications in TFS. This is typically used for common libraries and tools that several other application need to reference. When the libraries grow in size over time, so does the number of assemblies. So all solutions ......

Posted On Wednesday, December 15, 2010 1:59 AM

Dependency Replication with TFS 2010 Build
Some time ago, I wrote a post about how to implement dependency replication using TFS 2008 Build. We use this for Library builds, where we set up a build definition for a common library, and have the build check the resulting assemblies back into source control. The folder is then branched to the applications that need to reference the common library. See the above post for more details. Of course, we have reimplemented this feature in TFS 2010 Build, which results in a much nicer experience for ......

Posted On Wednesday, December 8, 2010 8:02 AM

TFS 2010 DeepDive i Stockholm i oktober
Note: Swedish post Efter att ha kört många seminarier, workshops och deep dive kurser på Visual Studio och TFS 2010 i Norge är det nu äntligen dags för oss att köra kurs i Sverige! Första tillfället blir nu i oktober på Cornerstone 18-21 Oktober. Saxat från kursbeskrivningen: T359 - Effektiv systemutveckling med Visual Studio och Team Foundation Server 2010 I denna utbildning lär vi dig hur du och din organisation kan effektivisera systemutvecklingsprocessen med hjälp av Visual Studio och Team Foundation ......

Posted On Friday, September 3, 2010 2:08 AM

Performing Checkins in TFS 2010 Build
Update 15.03.2014 - Fixed broken link to download*** The custom activity is availabe for download here: https://onedrive.live.com/r... *** Often when creating different types of release builds (e.g. where you build something that should be installed or consumed by other applications) there is a need to check in the results of the build back to source control. A common build type for us at Inmeta is Library Builds, which we use for common libraries that are shared among ......

Posted On Wednesday, November 3, 2010 10:20 AM

Managing Build Process Templates in TFS 2010 Build
One of the great new features in TFS 2010 Build was the ability to define Build Process Templates that can be reused across build definitions. The Build Process Template file itself is a Windows Workflow 4.0 xaml file and can be stored anywhere in source control. When a developer creates a new build definition in Team Explorer, he can choose from a list of Build Process Templates: This list is populated with the following build process templates: The ones that come out of the box (DefaultTemplate.xaml, ......

Posted On Wednesday, November 3, 2010 2:23 AM

Developing and debugging Server Side Event Handlers in TFS 2010
Update 2012-01-23: Added note about .NET framework Martin Hinshelwood wrote an excellent post recently http://nakedalm.com/team-fo... ) about a new type of integration available in TFS 2010, namely server side event handlers, that is executed within the TFS context. I wasn’t aware of this new feature and as Martin notes, there doesn’t seem to be any material/documentation of it at all. Previously, when you wanted some custom action to be executed ......

Posted On Wednesday, October 27, 2010 10:48 PM

Merging Work Items in TFS 2010
In TFS 2010, branching and merging have been greatly improved with support for branch visualization and tracking of changesets and work items across branches. A simple example of this looks like this: Here we track Work Item nr 3 which was originally resovled in the Test branch (with changeset 35). We can also see that the work item has been merged into the Production branch (as changeset 37), back to Main (62) and finally to FeatureC (140). If we switch to the Timeline view, we get a nice view of ......

Posted On Wednesday, October 27, 2010 8:10 AM

TFS Team Build 2010: How to place the build output to a fixed location
By default, TFS Team Build creates a new folder in the drop location for every build. I have seen request from people that wonder how to always have team build put the output in the same folder every time, effectively overwriting the results from the last build. This is easy to accomplish by adding an activity that copies the drop folder to a fixed location. To copy the result of the build to a fixed location, you need to modify the build process template: Open the build process template XAML file ......

Posted On Wednesday, September 1, 2010 8:47 AM

TFS 2010 Build: Dealing with the API restriction error
Recently I’ve come across this error a couple of times when running builds that exeucte unit tests using Test containers: API restriction: The assembly 'file:///C:\Builds\<path... has already loaded from a different location. It cannot be loaded from a new location within the same appdomain. Every time I’ve got this error, the project has been a web application, and the path to the assembly points down to the _PublishedWebsites directory that is created beneath the Binaries folder ......

Posted On Tuesday, June 8, 2010 6:08 AM

Building Visual Studio Setup Projects with TFS 2010 Team Build
UPDATE: 2010-09-15 – Added details about the use of the ExitCode variable One of the most common complaints from people starting to use Team Build is that is doesn’t support building Microsoft’s own Setup and Deployment project (*.vdproj). When creating a default build definition that compiles a solution containing a setup project, you’ll get the following warning: The project file "MyProject.vdproj" is not supported by MSBuild and cannot be built. This is what the problem is all about. MSBuild, ......

Posted On Friday, May 14, 2010 8:38 AM

Speed up loading of test results from builds in Visual Studio
I still see people complaining about the long time it takes to load test results from a TFS build in Visual Studio. And they make a valid point, it does take a very long time to load the test results, even for a small number of tests. The reason for this is that the test results is not just the result of the test run but also all the binaries that were part of the test run. This often also means that the debug symbols (*.pdb) will be downloaded to your local machine. This reason for this behaviour ......

Posted On Sunday, May 9, 2010 11:04 PM

Executing legacy MSBuild scripts in TFS 2010 Build
When upgrading from TFS 2008 to TFS 2010, all builds are “upgraded” in the sense that a build definition with the same name is created, and it uses the UpgradeTemplate build process template to execute the build. This template basically just runs MSBuild on the existing TFSBuild.proj file. The build definition contains a property called ConfigurationFolderPath that points to the TFSBuild.proj file. So, existing builds will run just fine after upgrade. But what if you want to use the new workflow ......

Posted On Wednesday, May 5, 2010 12:04 AM

Reember to uninstall all Beta 2 stuff before upgrading to VS 2010 RC
Yesterday I upgraded my dev laptop to VS 2010 RC. To upgrade to VS 2010 RC you need to first uninstall VS 2010 Beta 2 (which doesn’t really make it an upgrade does it? :-) I also hade an instance of TFS 2010 Beta 2 om my machine so I uninstalled that as well. The installation of VS 2010 went fine, and then I installed Team Explorer 2010 RC. However, when starting VS and switching to the team explorer, I got the following error: Could not load type 'Microsoft.TeamFoundation.C... ......

Posted On Tuesday, February 9, 2010 8:52 PM

TFS 2010 – Managing Build Agents using the API
In previous versions of TFS, you installed TFS Team Build on the build server and you got one build service agent. It was/is possible to start several build agents on the same server, but it is a bit of a mess. In addition, for each team project TFS 2008 build service can only execute one at a time (Note that builds from different team project can execute in parallell, a lot of people still don’t know this) In TFS 2010, the concept of build controllers were introduced. A build controller belongs ......

Posted On Tuesday, December 8, 2009 8:47 PM

TFS 2010 Beta 2 – Upgrading Builds from TFS 2008
We are in the process of upgrading the entire company to TFS 2010 Beta 2, and in preparing for that we have done some test upgrades to make sure that all things work as expected after the upgrade. As expected, most issues that turned up had to do with builds. This is one of the areas that has changed the most compared to TFS 2008. I thought that I would use this post to run through some of the issues that we found. First of all, when upgrading a TFS 2008 to TFS 2010 Beta 2, all build definitions ......

Posted On Tuesday, November 24, 2009 8:23 PM

TFS Team Build 2010: Working with Custom Code Activities
Disclaimer: This blog post discusses features in the TFS 2010 Beta 1 release. Some of these features might be changed in the RTM release. In TFS 2010, Microsoft has changed the build orchestration language in Team Build from MSBuild to Windows Workflow 4.0. Aaron Hallberg has written a post on how to implement a custom workflow activity using either the workflow designer or using a code activity that composes an activity. In this post, I will show how to implement a “pure” code activity, i.e. no ......

Posted On Thursday, August 13, 2009 9:38 AM

Modify Build Failure Work Item in TFS 2010 Build
The default behaviour in TFS Team Build (all versions) is to create a bug work item when a build fails. This main benefit of this is that you get a work item for something that needs to be done, namely to fix the build!. When the developer responsible for the build failure has fixed the problem, he/she can associated that check-in with the work item that was created from the previous build failure. In TFS 2005/2008 you could modify the information in the created work item by changing some predefined ......

Posted On Wednesday, April 28, 2010 8:15 AM

Creating a Build Definition using the TFS 2010 API
*** UPDATE 2010-08-17 ** Several people have asked me for a complete sample application, so I have put this together and it is available here: http://cid-ee034c9f620cd58d... **** In this post I will show how to create a new build definition in TFS 2010 using the TFS API. When creating a build definition manually, using Team Explorer, the necessary steps are lined out in the New Build Definition Wizard: So, lets see how the code looks ......

Posted On Monday, April 26, 2010 8:09 PM

Getting TF215097 error after modifying a build process template in TFS Team Build 2010
When embracing Team Build 2010, you typically want to define several different build process templates for different scenarios. Common examples here are CI builds, QA builds and release builds. For example, in a contiuous build you often have no interest in publishing to the symbol store, you might or might not want to associate changesets and work items etc. The build server is often heavily occupied as it is, so you don’t want to have it doing more that necessary. Try to define a set of build process ......

Posted On Wednesday, April 21, 2010 11:52 PM

Implementing Release Notes in TFS Team Build 2010
In TFS Team Build (all versions), each build is associated with changesets and work items. To determine which changesets that should be associated with the current build, Team Build finds the label of the “Last Good Build” an then aggregates all changesets up unitl the label for the current build. Basically this means that if your build is failing, every changeset that is checked in will be accumulated in this list until the build is successful. All well, but there uis a dimension missing here, regarding ......

Posted On Thursday, April 15, 2010 11:50 PM

VSTS 2010: Enabling Test Impact Analysis
A really cool new feature in VSTS 2010 is Test Impact Analysis which let developers view what tests that are affected by the current code changes. Pieter Gheysens wrote a blog post on how to set this up in the CTP, but things have changed a bit in Beta 1 so I thought that I would show how it is done. Since it still is a bit unintuitive to enable it, it might change once again in the RTM. The reason that it is a bit unintuitive to set it up, is because you need to have the following things: You must ......

Posted On Thursday, June 4, 2009 6:08 PM

TFS Team Build 2010: Executing Unit Tests
There are some changes and improvements in the area of executing unit tests in Team Build 2010. Mostly the changes make it easier to define which unit tests you want to execute as part of the build. In this post I will go through the different options that you have when it comes to running unit tests and enabling code coverage. To configure test settings for a Team Build, you select Edit Build Definition in Team Explorer, and then go to the Build Process tab. In the Build process parameters box there ......

Posted On Wednesday, June 3, 2009 10:27 PM

Working with Build Definitions in TFS Team Build 2010
Disclaimer: This blog post discusses features in the TFS 2010 Beta 1 release. Some of these features might be changed in the RTM release. In my last post I talked about the new major features of Team Build in TFS 2010. This time, I will go into more detail on how you work with build definitions. In TFS 2010, the whole build process is now implemented on top of Windows Workflow Foundation 4.0 (WF4). This means that everything that has to do with creating and customizing builds in TFS 2010 is now done ......

Posted On Wednesday, May 27, 2009 10:17 PM

TFS Team Build 2010: What’s New?
VSTS 2010 Beta 1 is finally available. Beta 1 is a huge release a contains tons of new functionality in almost all areas of Team System. We at Osiris Data have been using Team System since the first beta, and we also help our customers how to adopt TFS in their organization. So for us VSTS 2010 is a very exciting release. I am planning to post several blog entries about the new functionality of VSTS 2010, in particular I will focus on Team Foundation Server (TFS) and Team Build. I have been working ......

Posted On Saturday, May 23, 2009 11:10 PM

Free Seminar on Visual Studio Team System 2010 in Oslo, Norway
On May 20th Terje and Mikael from my company (Osiris Data) will hold a seminar in Oslo, Norway where they will run through all (?) the new cool features in VSTS 2010. Expect to see demos on the new functionality for manual and UI testing, branch visualization, hierarchical work items, gated check-ins and lots of other stuff. VSTS 2010 is a really huge release and if the rumours are true, the Beta 1 will be released in May, hopefully before the seminar :-) Check out the full agenda and registration ......

Posted On Wednesday, April 22, 2009 9:14 PM

Copyright © Jakob Ehn | Powered by: GeeksWithBlogs.net | Join free