WiX: Integrating into the continuous build

I've been working on a WiX installer recently and I was asked to integrate it into the project's continuous build process.  This turned out to be surprisingly easy.

Early on in the development, I decided to use WiX version 3.  It is nicely integrated with Visual Studio and has some great property windows for controlling compiler and linker behaviour.  So my development environment for WiX looks like this and I can create my MSI directly from the Build menu (or Ctrl-Shift-B, as I prefer):

wixproj3

The other benefit of WiX 3 is that the main project file (xxx.wixproj) is now actually an MSBuild script (this is a change to prior versions). 

Now our continuous build has CruiseControl.Net calling an MSBuild script (similar to the setup I described in a previous post). This means that once you got the latest binaries and files into the correct folders, getting the WiX project to build is as simple as:

<MSBuild Projects="$(InstallerDirectory)\Installer.wixproj" Targets="Build"/>

How cool is that?

blog comments powered by Disqus