Is it possible to pass property values defined in cruisecontrol config.xml to the ANT build.xml which is being called from the config.xml?

scott123's picture
scott123 asked on May 3, 2011 - 9:55am | Replies (1).

Ex: in config.xml I have defined the property as:

<property name="build.name" value="TestBuild" />

and In build.xml for ${build.name} it should resolve to "TestBuild".

Appreciate your answers.

Tags: 

1 Answer

tepidhobbes's picture

In CruiseControl's ant task, you can pass a property as a subelement like so:

<schedule>
<ant target="target_name" ... >
<property name="build.name" value="build123"/>
</ant>
</schedule>

You can also try using the 'propertyfile' attribute to pass an entire property file (useful if you change those values externally).

Hope this helps

CMCrossroads is a TechWell community.

Through conferences, training, consulting, and online resources, TechWell helps you develop and deliver great software every day.