user3689167
user3689167

Reputation: 873

WiX + Heat, harvesting a directory but not including parent folder in installation

I have a pre-build event for a wix installer, it looks like this:

"%WIX%\bin\heat.exe" dir %SystemDrive%\Staging -dr INSTALLFOLDER -cg Components -var "var.Project.TargetDir" -ag -out "$(SolutionDir)Project.Installer\Installer.Heat.wxs"

It takes all the files in C:\Staging and makes a .wxs for the components which is great. However, when I run my installer, it drops all of the files to C:\Program Files(x86)\MyInstallFolder\Staging"

I need to harvest all the files in the staging directory, but I would like to output them in just the INSTALLFOLDER (no staging directory). How do I achieve this using heat?

Upvotes: 2

Views: 1564

Answers (1)

Yan Sklyarenko
Yan Sklyarenko

Reputation: 32240

Try -srd switch of the Heat command line. It suppresses harvesting root directory as an element.

Upvotes: 6

Related Questions