ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manik Surtani <manik.surt...@silkroad.co.uk>
Subject Looping in ANT
Date Mon, 12 Nov 2001 15:03:32 GMT
Hello, all.

I have noticed a problem with ant, and that is performing loops.

If I want a set of tasks to repeat several times based on a set of 
properties, the only way I can do this is using the <script> tags, and 
perform the loops in javascript.

Also, it is not possible to use the <script> tags to envelope a set of 
tasks to loop through, such as:

<script language="javascript">
for (i=0; i<10; i++)
{
</script>

<echo message="This is my task to be repeated" />

<script language="javascript">
}
</script>


Instead, I have to create and execute the task in Javascript, which 
really takes away from the whole ANT XML build script thing.  

My current J2EE build script runs almost everything in a loop, so this 
means almost the entire build.xml is just Javascript!!  

Is there an alternate way to do this?  

Also, who is the maintainer of the <script> tasks?  I am keen to know if 
such functionality (as described above) could be possible - I am 
volunteering to help develop the <script> task, but I need to get more 
famniliar with the task first.

Cheers,

-- 
Manik Surtani
Chief Technology Officer
Silk Road Limited

Telephone: 07786 702 706
Email: manik.surtani@silkroad.co.uk
Web: http://www.silkroad.co.uk




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


Mime
View raw message