views:

99

answers:

2

Currently the msbuild logs for team build are appalling as they are just plain text and are very difficult to read. Also the ones created by my build are approx 30Mb and take quite a while to download (our TFS server is in our datacentre).

Does anyone know any way of being able to view these logs easier, prefereably integrated with either TFS itself or TFS WebAccess?

+1  A: 

If increasing bandwidth isn't an option then I would suggest you to write your own html logger and attach it to the build process. Splitting the html build log into minor parts (definded by targets and/or projects) and having one index file pointing to all the minor parts with appropiate information whether a given part failed or succeeded. Then you only need to parse the index file and any requested part over the link.

A third possibility is to compress the log-file after the build completes.

All the best /Niels

Niels Harre
+2  A: 

Take a look at the following blog post I did a while ago:

http://www.woodwardweb.com/teamprise/000415.html

This describes how to create a simple ASP.NET page that will stream the contents of your log file to you over HTTP. The advantage of doing it this way is that you don't have to wait for the entire page to load before the log starts to render for you in Visual Studio.

Also - you can add some simple formatting to the file while streaming. In the example on my blog I simply make the start of each target appear in bold to make them stand out a bit more, but you can see how you could go crazy with this approach if you wanted.

Hope that helps,

Martin.

Martin Woodward
Thanks Martin I had seen your blog post before but couldn't find it again. Thanks for the link. I think I might implement yours to start with so I can at least view the logs resonably quickly.I've also found a few posts about adding custom loggers which might be a nice endpoint, your aspx view that maybe does an xsl transform on a custom logged msbuild file.http://blogs.msdn.com/aaronhallberg/archive/2006/08/30/adding-custom-loggers-to-team-build.aspx
caveman_dick
That would be pretty cool. If you wanted to share the code that you ended up with I know that plenty of people would be interested - might even make a nice little CodePlex project!
Martin Woodward