Published on

Sometimes it is convenient to set project variables at build time. There are a couple of ways that this can be accomplished:

Use the preBuildActionList:

<prebuildactionlist>

<setinstallervariable name=“version” persist=“1” value=“${env(BUILDVER)}” />

</prebuildactionlist>

Or, starting with 5.4.6, it is possible to pass variables directly in the command line to the builder

$ builder build project.xml --setvars version=1.2.3 project.shortName=newName