ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jon Stevens <...@latchkey.com>
Subject more <delete> madness
Date Mon, 12 Mar 2001 17:44:34 GMT
Ok, so I want to be able to have a target that allows me to clean up after
running my testing suite. However, if my testing suite hasn't been run yet,
then the results directory doesn't exist.

  <target name="test-clean">
    <delete quiet="true" includeEmptyDirs="true">
        <fileset dir="${test.home}/templates/results/">
           <include name="${test.home}/templates/results/**/*.res"/>
        </fileset>
    </delete>
  </target>

Now, if I run the above target while the directory doesn't exist, I get this
error:

/Users/jon/checkout/jakarta-velocity/build/build-testcases.xml:142:
/Users/jon/c
heckout/jakarta-velocity/test/templates/results not found.

I suspect that this is coming from the <fileset> now. It would be nice to
have it optionally also not fail when a directory doesn't exist.

My workaround hacky solution is to simply <mkdir> before executing the
<delete> task, but that is annoying.

thanks,

-jon


---------------------------------------------------------------------
To unsubscribe, e-mail: ant-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: ant-dev-help@jakarta.apache.org


Mime
View raw message