ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject Re: <ant/> properties
Date Thu, 12 Aug 2004 09:23:06 GMT
On Wed, 11 Aug 2004, sebastian ssmoller <>

> passing properties to the new project using this code snippet 
> <ant ...>
> 	<property file=""/>
> </ant>
> all these properties in the "" are evaluated in the
> context of the new project right?  

Yes.  Technically the property elements are <property> tasks run
inside the new project.

> so a property like "deploy=${basedir}/deploy" in the
> will be set relative to the basedir to the new
> project rather than to the old one - correct ?

It depends the values of the dir and inheritall attributes of your
<ant> task - see the table in <ant>'s manual page.  Technically it is
the basedir of the new project, but that may be different from the
<project> element's basedir attribute.

> and if i want to behave <ant/> the other way round (deploy relative
> to the basedir of the calling project) i have to add all these
> properties manually like this:

Or set the dir attribute of the <ant> task.

> did i miss something ?


You can load the properties file in your main build file, give them a
common prefix (or make them identifiable in any other way) and use a
<propertyset> to pass them down to your subbuild.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message