How To: Specify Long Command Lines to MSBuild

Sometimes when using MSBuild.exe the command lines can get pretty darn long and hard to manage. This is particularly true if you’re using a custom logger that takes parameters. I also ran into some trouble when I was trying to pass an escaped string to the custom logger via the Visual Studio UI for project…


Sprint 10 Backlog Items

My bad for not getting this up sooner. We’ve actually been going on Sprint 10 for the last two weeks. As with Sprint 9 we’ve split it into one sprint for platform work and one for dogfood work. We’ve made a shift in our platform work for Sprint 10. During this sprint we are solely…


How To: Perform Nightly Builds with Team Foundation Server

Edit: Ok, after talking with Khushboo and given Niels’s comment, it’s clear that the article I linked to is woefully out of date. Please ignore this post. If you want to perform nightly builds with Team Foundation Server, tfsbuild.exe is the tool to use. [ Author: Neil Enns ]


How To: Insert Custom Process at Specific Points During Build

Today Kieran, Faisal, and I met with one of our partners to give them an introduction to MSBuild. During the discussion one of them asked us about the different places someone can plug into the standard Visual Studio build process (as defined by the Microsoft.Common.Targets file). In general the way you hook into the existing…


MSBuild in Visual Studio Part 13: The Three Custom Loggers

We’re written in the past about how to write custom loggers, and you probably won’t be surprised to learn that Visual Studio makes use of custom loggers when interacting with MSBuild. There are three separate loggers, each with its own purpose. The project load logger is used when projects are opened. It discards all messages…


MSBuild in Visual Studio Part 12: Compiling Inside Visual Studio

We’ve touched briefly on how the Compile target is used by Visual Studio, but only on how it relates to Intellisense. Of course while Intellisense is nice, most people would like to actually compile a complete application using Visual Studio. If you’re reading this blog you likely already know that MSBuild is used for the…


How To: Conditionally Apply Metadata to Items

Last week we got a great question over on our forum about applying metadata to items depending on a condition. What the author wanted to was something like this:  <ItemGroup>  <Compile Include=””>   <DefineConstants Condition=” ‘$(Configuration)’ == ‘Debug’>OnForThisFile</DefineConstants>  </Compile> </ItemGroup> It isn’t documented in our MSDN reference (which we’ll get fixed), but as the original author discovered this works…


MSBuild in Visual Studio Part 11: Other Special Targets

The last two entries walked through how the Compile target is used by the IDE to drive certain features. There are a number of other targets that get called at various times. Several targets exist to help compute project output groups, which are sets of files related to the project. These are useful when the…


MSBuild in Visual Studio Part 10: What Does MSBuild Have To Do With Intellisense?

In our last post we started to dig into how the Compile target is used by Visual Studio at design time, and the details around the in-process compiler. When Rajeev was talking about the in-process vs. out-of-process compiler during the talk I must admit I started to doze off a bit. I’m much more of…


A Pretty Picture of Our Project Dependencies

As you may have noticed from our recent posts on build parallelization, we’re thinking a lot lately about project dependencies. One thing I’ve always wanted is a tool that let me visually look at the project-to-project references that make up my application. A couple of weekends ago I hacked together an application that uses the…