You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by ji...@korvac.com on 2002/04/17 08:23:04 UTC

is not working...

Hi,
  I am new to ant. I try to use <delete> to delete some files and folders.
But the error message says it is unable to delete the files.
  The buildClassesDir contains all the class files, whereas the distDir
contains the jar files. I am able to delete the ${buildClassesDir} folder
but not the ${distDir} folder. Therefore I have to delete it manually.
  I was able to delete both folders until I re-checkout the module from cvs
(this process is done manually, not the cvs tag in ant scripts). The error
says BUILD FAILED. Unable to delete .../.../ folder.
  May I know under what circumstances I cannot delete any folders?

<target name="cleanUp" >
     <delete dir = "${distDir}" />
     <delete dir = "${buildClassesDir}" />
</target>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


RE: is not working...

Posted by Conor MacNeill <co...@cortexebusiness.com.au>.
> From: jinwei@korvac.com [mailto:jinwei@korvac.com]
>   May I know under what circumstances I cannot delete any folders?
>

Under windows you may not delete a file (or directory) which is locked by a
process. This includes explorer if you are looking at the directory and also
the Java VM if the directory contains jars which are part of the classpath.

Conor


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>