Java Mailing List Archive

http://www.ant-tasks.com/

Apache Ant Archive

» Ant Users List
» Ant Developers List
Invoking a target (Ant 1.7) in a loop (Ant-Contrib)

Invoking a target (Ant 1.7) in a loop (Ant-Contrib)

2007-01-17       - By Steve Loughran
Reply:     1     2     3     4     5     6     7     8     9     10     >>  

Rebo, Alex wrote:
> Thank you, Steve!

>
> In my mind the "if-then-else" block looks cleanly this way.
> On top, target contra to macrodef can be executed conditionally
> (if/unless)
>
> You are correct pointing out that if a target can't be invoked all by itself
> (answer to your Q: "do you ever execute ant using that as a target or is it
> a utility type thing?"
> is "No") it should be a target.
> Per Dominique's suggestion I replaced "foreach" with "for" thus loosing the
> ability
> to call a target within loops body.
> If I can figure out how to put macrodefs in place of a target, I might try
> to "unload" the body of the loop.
>
> Do you think it's worse the effort, Steve?

well, I dont think you need to do any big loops or iteration. You can do
a bulk verify too, using verifyproperty=true

> PS.: Could you, please, elaborate on "In Ant 1.7, many support resources,
> which provides you
> even more ways to source data."?

yes, it gets detailed coverage in both the Ant 1.7 manuals and in the
forthcoming Ant in Action :)

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)


©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.