or...

3) Use <apply> to launch the Java command-line you want to run. Its not as elegant, but would work. You'll want to use parallel="true" to only run one command with all files on a single command-line.

Erik

Dominique Devienne wrote:
You have two choices:

1) Write an Ant-task. This task will accept a <fileset>, and process it.
It's actually simpler that it may seem at first, and is even trivial
when you don't need to use any of the Ant datatype/classes (in which
case you write a simple bean class with setters and an execute() method)

2) Use a <fileset> outside your <java> task, <pathconvert> it to a space
separated string stuffed in a property (that you seem to accet), and
simply dereference that property as an <arg>.

(2) might just be what you need, but (1) is fun and provides a nicer
interface to your particular functionality in the build file. It's all a
matter of choice, time available, willingness to learn something new, etc...

Good luck, --DD

-----Original Message-----
From: Jan Heise [mailto:jan@;janheise.de] Sent: Wednesday, November 06, 2002 11:27 AM
To: [EMAIL PROTECTED]
Subject: Q: expanding fileset to args for java-task

hi all,

perhaps this is a simple/silly question but I haven't
found an answer so far. I want to do the following:

say i have a java task like:
<java classname="cirrus.hibernate.tools.SchemaExport" fork="true">

this tool supports a list of files as input from the command line,
so obviously I want to do something like this:
<arg refid="mapping1.hbm.xml"/>
<arg refid="mapping2.hbm.xml"/>
<arg refid="mapping3.hbm.xml"/>

I am searching for a way to make this more flexible/shorter like
doing:
<arg>
<fileset dir="${dir.src}">
<include name="**/*.hbm.xml" />
</fileset>
</arg>

but this does not work. is there a way to achieve the above?

tia, jan




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

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




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

Reply via email to