Using the heat.exe tool to generate components
Sometimes, your software is going to require a lot of files: there's the main executable, supporting libraries, images, configuration files, help documentation, and potentially more. You might start out writing the Component
elements by hand, but pretty soon it's going to amount to more than you'd care to take on.
The WiX team has provided a tool called Heat to shoulder the burden. You can take this utility and point it at a directory of files, and it will generate the WiX markup for you. In this recipe, we'll try it out by creating a directory of text files and then run Heat to turn it into a .wxs
file. Heat is included in the WiX toolset.
Getting ready
To prepare for this recipe, perform the following steps:
On your desktop, create a folder named
SourceFiles
.Add three text files to it and name them
Sample1.txt
,Sample2.txt
, andSample3.txt
.
How to do it…
Call heat.exe
from the command line to convert a folder of files into the WiX markup using the...