<?xmlversion="1.0"?>
<projectname="javaTest"default="jar"basedir=".">
<targetname="clean">
<deletedir="build"/>
</target>
<pathid="classpath">
<filesetdir="lib">
<includename="*.jar"/>
</fileset>
</path>
<targetname="compile"depends="clean">
<mkdirdir="build/classes"/>
<javacsrcdir="src"destdir="build/classes"encoding="UTF-8">
<classpathrefid="classpath"/>
</javac>
</target>
<targetname="run"depends="compile">
<javaclassname="Main">
<classpath>
<!--<classpathrefid="classpath"/>-->
<pathelementpath="build/classes"/>
</classpath>
</java>
</target>
<targetname="copyConfig"depends="run">
<copytodir="build/classes">
<filesetdir="src">
<includename="*.png"/>
</fileset>
</copy>
</target>
<targetname="jar"depends="copyConfig">
<pathconvertproperty="mf.classpath"pathsep="">
<mapper>
<chainedmapper>
<flattenmapper/>
<globmapperfrom="*"to="lib/*"/>
</chainedmapper>
</mapper>
<pathrefid="classpath"/>
</pathconvert>
<jardestfile="main.jar"basedir="build/classes">
<manifest>
<attributename="Main-class"value="Main"/>
<attributename="Class-Path"value="${mf.classpath}"/>
</manifest>
</jar>
</target>
</project>
<projectname="javaTest"default="jar"basedir=".">
<targetname="clean">
<deletedir="build"/>
</target>
<pathid="classpath">
<filesetdir="lib">
<includename="*.jar"/>
</fileset>
</path>
<targetname="compile"depends="clean">
<mkdirdir="build/classes"/>
<javacsrcdir="src"destdir="build/classes"encoding="UTF-8">
<classpathrefid="classpath"/>
</javac>
</target>
<targetname="run"depends="compile">
<javaclassname="Main">
<classpath>
<!--<classpathrefid="classpath"/>-->
<pathelementpath="build/classes"/>
</classpath>
</java>
</target>
<targetname="copyConfig"depends="run">
<copytodir="build/classes">
<filesetdir="src">
<includename="*.png"/>
</fileset>
</copy>
</target>
<targetname="jar"depends="copyConfig">
<pathconvertproperty="mf.classpath"pathsep="">
<mapper>
<chainedmapper>
<flattenmapper/>
<globmapperfrom="*"to="lib/*"/>
</chainedmapper>
</mapper>
<pathrefid="classpath"/>
</pathconvert>
<jardestfile="main.jar"basedir="build/classes">
<manifest>
<attributename="Main-class"value="Main"/>
<attributename="Class-Path"value="${mf.classpath}"/>
</manifest>
</jar>
</target>
</project>