Thanks Diane, Dominique and Stephan. Resolved as below. -----Original Message----- From: Diane Holt [mailto:[EMAIL PROTECTED]] Sent: 20 March 2002 19:57 To: Ant Users List Subject: RE: Test if directory is empty
--- Dominique Devienne <[EMAIL PROTECTED]> wrote: > Haven't tried it myself, but from the doc I would say that <pathconvert> > would have converted your fileset the way you wanted. FWIW, --DD Yep -- <pathconvert> will turn a fileset into a printable list. And you could use it, in combination with <condition>, to test for an empty directory -- eg: <fileset dir="foodir" id="fs"/> <target name="doit" depends="chkdir" unless="noFiles"> <echo message="files = ${files}"/> </target> <target name="chkdir"> <pathconvert pathsep="," property="files" refid="fs"/> <condition property="noFiles"> <equals arg1="${files}" arg2=""/> </condition> </target> Diane ===== ([EMAIL PROTECTED]) __________________________________________________ Do You Yahoo!? Yahoo! Sports - live college hoops coverage http://sports.yahoo.com/ -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]> -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>