Thursday, May 31, 2007

Updating assembly version with Continuous Integration build: Part III

I wrote before about different ways to update assembly versions for multiple projects. Previous solutions included artificial shared state file which should reside in the Cruise Control . NET folder. This is additional deployment hassle, of course, but it offers a little bit different approach, than a natural way - using a Labeller task, specifically designed for these purposes.

Let's say, we still have two projects configured in CC.NET and resulting DLLs should be marked with the shared build number. The following snippet illustrates Labeller configuration:

<project name="ReleaseBuild">
<labeller type="defaultlabeller">
<!-- Other project configuration goes here -->

<project name="DailyBuild">
<labeller type="stateFileLabeller">
<!-- Other project configuration goes here -->

Now the ReleaseBuild project will increment the build number and DailyBuild will use it for it's purposes. There is a downside - now only ReleaseBuild has a control over the label but if we will create some rules around build use we can easily find ways to use this feature. On another side there is a huge advantage - Cruise Control dashboard and CCTray monitor show label, which is now a real DLL version...

No comments:

© 2008-2013 Michael Goldobin. All rights reserved