Chapter 5. Custom Loggers

We have identified that there are two ways to extend MSBuild: by custom tasks and custom loggers. In the previous chapter, we covered custom tasks; in this chapter, we will discuss custom loggers. We’ll start by discussing what loggers are available out of the box and how they can be used. After that we’ll take a look at what it takes to write and use a new custom logger. Now let’s get started.

Overview

One of the most important aspects of a build tool is its logging support. You can create the best build tool ever, but if the logging mechanism doesn’t meet the needs of consumers then it will never be used. MSBuild has a great deal of flexibility with respect to loggers. There are two loggers that are shipped with MSBuild: ...

Get Inside the Microsoft® Build Engine: Using MSBuild and Team Foundation Build now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.