Reputation: 1430
I would like to harvest a directory using Heat which contains a lot of files and not all of them should go into installation. However, i have a list of files that should be included in another XML in this format:
<?xml version="1.0" encoding="utf-8"?>
<FileSystemList>
<File Path="\some_folder\some.file" />
...
</FileSystemList>
It could just as well be a simple text file with one file per line.
I already have a XSL transform which i can specify a file to exclude but it's not really appropriate if you have hundreds of files. I know almost nothing about XSL (been using samples i could find) so i would appreciate a help to somehow include this xml/txt file into the XSL which heat will use and exclude the files in the list.
Upvotes: 0
Views: 849
Reputation: 1
In this case, XSLT removes all xml files except "Config.xml":
<xsl:key name="XmlToRemove"
match="wix:Component[ substring( wix:File/@Source, string-length( wix:File/@Source ) - 3) = '.xml' and not (contains(wix:File/@Source, Config.xml))]"
use="@Id"/>
...
<xsl:template match="wix:Component[key('XmlToRemove', @Id)]" />
Upvotes: 0
Reputation: 21896
Heat doesn't support that. Instead, use your build engine (e.g., MSBuild) to create a staging area that contains only the files you want to harvest.
Upvotes: 3