ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: changing the main initialization procedure
Date Fri, 24 May 2002 03:08:49 GMT
Hi,

On Thu, 23 May 2002 16:51, Nicola Ken Barozzi wrote:
> Peter Donald (have to use full name because this list is soooo full ;) ,
> any hint on how to include a basic templating mechanism with current Ant? I
> recall you favor templating, and I'm sure you can help us (I'm interested
> too) and give us some advice.

The way I would suggest to do things with the current ant is the following. 

Create a master build file that contains delegating targets. Each of these 
targets just generate the real build file(s) from the template and then call 
the actual target. ie an example delegating target may be

<target name="clean" depends="gen-buildfiles">
  <ant antfile="mynewbuild.xml" target="clean"/>
</target>

An example of this in action (mainly done by Adam) is available in the 
jakarta-ant-myrmidon CVS. 

Have a look at

jakarta-ant-myrmidon/build.xml (Master build file)
jakarta-ant-myrmidon/tools/xsl/build.xsl (Template file)
jakarta-ant-myrmidon/*/project.xml (Input data files)

-- 
Cheers,

Peter Donald


--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message