How to handle variable substitution for self defined variables

Apr 9, 2010 at 8:40 AM

I've been looking at the documentation, but couldn't something about this. I would like to automate as much as possible and for me to start using dotNetInstaller, I would have to be able to parameterize the bootstrapper build. The download URL for instance will have to be different when building to different environment (systest, staging, production). What is considered the best practice on how to handle this?

Coordinator
Apr 9, 2010 at 2:13 PM

We handle this outside of the bootstrapper capabilities.

We use ANT, so we preprocess the configuration.xml

<copy file="${bootstrapper.dir}/configuration.xml" tofile="${build.dir}/configuration.xml" overwrite="true">
<filterchain>
<expandproperties />
</filterchain>
</copy>

The configuration file has $(variable) in it. Then invoke InstallerLinker.exe on the output.

 

Apr 9, 2010 at 2:48 PM

Yeah - I kind of landed on using MSBuildTasks's TemplateFile for MSBuild.