ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Frot" <f...@lycos.at>
Subject Looping through files in the buildfile
Date Sat, 08 Jun 2002 12:24:41 GMT
Hi all,

I have two seperate, but simular. problems.


First I would like to create a classpath dynamically using all available library files present
in the projects "./lib" directory.
The classpath (or a property) will look like './lib/mylib.jar,./lib/junit.jar'
I have seen a mail once solving this for the classpath part, but never for the property....
Can someone give an example for both options classpath an property ?


Secondly I would like to call a task for every file present in a directory, somthing like
:

	<loop dir="./database_scripts" files="*.sql">
		<echo message="processing file : ${FILE}" />
		<antcall target="executeSQL">
			<param name="sqlfile" value="${FILE}" />
		</antcal>
	</loop>

note : where ${FILE} is ofcourse each time a different file name.
I guess this would need some special task (loop)  to be implemented, any suggestions on how
to tackle this ???

Thanx,

Fred


--
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