ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bill Kelly <>
Subject Re: Specifying repeated tasks: loops, sub-tasks, ...?
Date Mon, 04 Sep 2000 15:17:28 GMT
Stefan Bodewig wrote:

> >>>>> "BK" == Bill Kelly <> writes:
>  BK> Has the list ever discussed making it easier to do repeated
>  BK> actions, or specify many similar sub-tasks using loops or
>  BK> sub-tasks or some existing feature I've missed?
> Yes and no. Procedural logic has been ruled out several times

I suspected as much - but I think the price you pay in avoiding it by
doing copy-paste in your XML file is very high.

> you are going to find that <ant> could help you out here.
> ...So "procedure calls" are already supported.

True, ant tasks let you parameterize values, and they have no 'memory'
from one task to the next, so you can use the same target.

> What's missing now is the loop construct if you don't want to retype
> the stuff all over and over again. You could use the <script> task or
> write your own Java task to get this.

Hadn't used it up to now, but the examples look quite useful.  Thanks for
the tip.

> Somewhat off topic:
>  BK> The JUnit task provides its own solution to this, but again in a
>  BK> very specific way.
> The task you are referring is different from the one in the Ant
> distribution, do you think we could merge some useful features from it
> with the version in Ant's current CVS tree.

I know that you and Tom Haas worked on JUnit integration  I looked at
junit.html from the latest build, and thought it looked recognizably
similar to the version I have from Tom, but I see there are some major
differences.  We can talk off-line.

View raw message