It looks like I’m not the only one who wanted a debugger for MSBuild projects. When the MSBuild team asked everyone to spend $100 to prioritize features, the runaway winner was a debugger. Reading the comments to my original post (as well as the MSBuild team’s posts), Partho Das from Microsoft has released a Visual Debugger for MSBuild projects! It’s an alpha, but was more than enough for me to single step through all my complicated MSBuild scripts. The following screen shot shows the UI on a loaded project and I’ve set a breakpoint on my All target.
One quick hint when you start debugging a project is that the Choose Target for Debugging dialog that pops up is not just limited to the three default target and you can enter any target name you want.
As you can see in the screen shot, there’s support for call stacks, property viewing, and item viewing. This is a really great start to something we could all really use. Partho has set out what he’s doing for version two and will be releasing the source code soon.
Speaking of MSBuild feature requests, I need to mention that Attrice has a very interesting tool in their MSBuild Sidekick. While it only supports Visual Studio 2005 and .NET 2.0 projects right now, there are many things that look quite interesting and address numerous of the features people voted for. For example, the Targets Diagram view shows the relationships between your tasks. The easy project editing also looks very enticing as manually editing custom MSBuild project files gets very old very quickly. Eugene Zakhareyev has tentatively promised to add MSBuild 3.5 projects support and “some level of step-through debugging.”I’m starting to play around with MSBuild Sidekick and will report how it goes.
While the MSBuild team got the message about an MSBuild debugger, it looks like the community was already out there trying to solve the problem. That’s a huge win for everyone!