You could use PathConvert to convert your fileset into a string with the list of files.  You will probably want to set pathsep=" " and use arg line="${fileslist}".

So, you have:
<pathconvert pathsep=" " property="fileslist">
   <fileset dir="${workingdir} includes="*.java"/>

<java  classname="Test.Main">
   <arg value="-all" />
   <arg line="${fileslist}" />

I haven't tried it, but it should work.


Please forgive my stupidity, but I have spent hours on this ...

Given the following Unix/Linux command line:

         java  Test.Main  -all  *.txt

I wrote the following ant task:

         <java  classname="Test.Main">
             <arg value="-all" />
             <arg value="*.java" />

Test.Main reports it cannot find file *.java.

So I replaced the 2nd arg with a <fileset ... />.
The ant java task reports that it does not accept <fileset>'s.

Similarly, I tried nesting a fileset within an arg.  Illegal.

I checked the O'Reilly Ant book and
without finidng a solution.
I am clearly missing something.  It should not be this hard.


To unsubscribe, e-mail:
For additional commands, e-mail:

No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.12.5/150 - Release Date: 27/10/2005