jose alberto,

i do not understand why you say "...by using some order list that no one really 
knows why that order and not another...", i think this is purely matter of 
documentation.

i understand that using the depends attribute on targets makes ant (not the 
developer) to flatten the dependency graph into a sequence.

the thing is that that requires changes to the build files. the approach i took 
was to have generic build xml files (usable by different projects) and the 
specific of the project/developers be in properties files.

by doing this the build files can be leveraged across projects.

regards.

a

Jose Alberto Fernandez wrote:

> From: "Alejandro Abdelnur" <[EMAIL PROTECTED]>
>
> > craeg,
> >
> > > Can you give an example where you would need an ordered collection,
> > > rather than a set?
> >
> > yes i can.
> >
> > i've built a development environment based on ant for a big project (35K 
> > source files - java, html, jsp, xml, etc.), it takes
> > care of building (compiling), deploying (token replacement) and installing 
> > (copying stuff to the right place). the project is
> > divided in several functional modules that evolve at their own speed, each 
> > module has a set of source files. this functional
> > modules create a non cyclical graph of dependencies for the building 
> > process, i.e.: to build module C you need module B
> > already built, and for building B you need A built first. the master build 
> > file goes over all the modules in the
> > *defined* order building them.
> >
> > if the order is not enforced the build fails.
> >
>
> This is exactly the kind of misuse of foreach that keeps people rejecting its 
> formal introduction.
> What you are doing is hiding the real dependencies between your different 
> modules, by using some order list that no one really knows why that order and 
> not another. This to me is bad.
>
> The whole point of ANT is making those dependencies explicit so that the 
> build is maintainable, so you should be using targets and dependdencies and 
> let ANT pick the correct building order. If at some point new modules are 
> added with new dependencies, you just need to list them and ANT will rearrage 
> the building process as needed.
>
> IN any case, you were already citing all the modules by name in your order 
> list, so there is no diference here.
>
> Jose Alberto
>
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com

Reply via email to