i have an xml script for building a project out of this structure.
- src
- src files and package subdirs
- rsrc
- build.xml
After building out of the src folder there is a build and lib folder created in rsrc
- src
- src files and package subdirs
- rsrc
- build
- package subdirs
- lib
- build.xml
- build
After everything worked, the build folder is filled with the .class files, in their package subdirs. In the lib folder the distribution .jar has it's place. Now to my problem i wrote this target named= "clean":
<target name="clean"
description="clean up" >
<!-- Delete the ${build} directory tree -->
<delete dir="${build}"/>
</target>
Which should delete the build folder, its subfolders and contents. The $ Build is defined as:
<property name="build" location="build"/>
and the base directory as basedir="."
But nothing gets deleted, what am I doing wrong.
Best regards Stefan (If you need additional information just ask please)
EDIT: If i call it with "ant -v clean" the build file is deleted .. if i call with "ant" or "ant -verbose" its not.
ant -v clean
. That will show you exactly what Ant is trying to delete. (And ignore the answers which recommend using ${basedir}/build—they apparently aren't aware that relative paths in Ant are already treated as relative to the basedir.) – VGR