ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Pringle <>
Subject repeating a target on a "fileset"?
Date Wed, 14 Feb 2001 17:37:05 GMT
I assume I could do this with a <script> task, but don't have time to learn
BSF right now.  Currently I have two cmd scripts (NT) that do the work - I'd
like to translate to ant.  First script:

build-ejb <working dir> <ejbname>

will build a single ejb.  The ejbs follow a convention that the
package/directory name is the same as the bean jar file name.  I got this to
work fine with the <jar> and <java> tasks (couldn't get the <ejbjar> task
work the same and gave up due to time constraints).  I then made the
"build-ejb" target "generic" and have other targets call it with <antcall>
and pass the parameter of the ejb name.  This works fine.

The problem is that there are almost 50 EJBs, and I don't want to create 50
individual targets!  The "build-all-ejbs" cmd script basically does this:

FOR /D %%i IN (%ejbpath%\*.*) do CALL %EJBCOMMAND% %FILES% %%~ni

Is there some way to do the same thing in Ant?  Have some target that could
either build a single, designated EJB or build for every subdirectory?


View raw message