ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From robert burrell donkin <>
Subject Re: PATCH: Attributes of Target can reference properties
Date Fri, 06 Jul 2001 00:25:43 GMT
On Thursday, July 5, 2001, at 07:28 AM, Tim Vernum wrote:

>> (...putting flame-proof boots on...)
> Darn it!
> It's not fun then :)

you can't flame me - i'm a guest :)
once i've managed to proof-read and submitted my documentation patchs i'll 
happily slither back to the nether-reaches of jakarta from whence i came..

>> once you go down the road of introducing features that more
>> right belong
>> in scripting languages, where are you going to stop?
> Without actually wanting to debate your conclusion, I don't
> necessarily agree with your assumptions.
> "features that more right[ly] belong in scripting languages,"
> This assumes some or all of the following:
>  * Build processing is not/should not be a script-driven process
>    People suggest that Ant should be purely declarative, and
>    not handle scripting.
>    Sometime I get the impression that they believe that build
>    processing has nothing to do with scripting.

i meant that though scripting may be part of the build process,
i'd prefer the scripting language to be orthogonal to the build language.

1. why re-invent the wheel (or in this case velocity)?
2. xml-syntax sucks for scripting.

>  * There is a set of build processes that require scripting,
>    but Ant does not attempt to support them.
>    Alternatively, builds may need scripting, but that's not
>    something ant wants to participate in.

i would say that there's a difference between facilitation and modifying 
the core syntax. i'd say that ant should support scripting builds but can 
and should do this without polluting the core xml.

>  * Ant is not and should not be a "scripting language"
>    I mostly agree with this, but I don't think it is a forgone
>    conclusion. Scripting is not evil, and if build processing
>    requires scripting, then they may be use for it *in*
>    Ant.
>    To some exent this is what Peter V is requesting, he probably
>    accepts that "foreach" leads to scripting, but he believes
>    that scripting is a necessary part of the the build process.

i'd say that Peter's list of stuff that he'd like to see ant do is pretty 
much equivalent to velocity - and in my book, that's not leading to 
scripting, that actually implementing an ant scripting language within the 
core syntax. since ant uses xml syntax this is probably going to end in 

   * Scripting in/with/for ant should be separate from the build
>    process within the ant core.

yep - that's the crux of my argument.

>    Some suggestion XSLT, some suggest <script>, some suggest
>     another form of templating.
>    I did raise an Ant2 requirement that Build Files should be
>     able to be dynamically created, so I guess I fall into
>     the last group.

they can already be. just use the texen ant task and velocity scripting.

>> that way you can use a proper, fully functional scripting
>> language such as
>> velocity to design your templates. when you run the main
>> build script, use
>> (for example) the texen task to generate your specialized
>> build script
>> from your template and run the generated script all from within ant.

(maybe i should have posted pseudo-code instead :)

> Right now, ant1 doesn't do this cleanly enough.
> In (GNU)make, you can make Makefile includes, dependant on something else,
> so that you can regenerate it (relatively) cleanly.
> Ant doesn't currently support this, so you have to wrap ant in another
> tool, and then you have to handle the ant options etc.
> It's possible, but it should be easier (and I hope that Ant2 will be).

as i said i'm not a build expert so i'll take your word for that.
if i was faced with the same problem, though, i would have approach it 
through generation (using a master ant build script) of intermediary build 

i suppose that the reason that i posted in the first place is that
it would have taken me about 3 minutes to write an ant generative build 
script to do
pretty much what peter wanted - without any changes to the ant source.

- robert

View raw message