30 lines
889 B
XML
30 lines
889 B
XML
<project name="SpaceShipSim" basedir="." default="main" >
|
|
<property name="src.dir" value="src" />
|
|
<property name="bin.dir" value="bin" />
|
|
<property name="classes.dir" value="${bin.dir}/classes" />
|
|
<property name="jar.dir" value="${bin.dir}/jar" />
|
|
<property name="main-class" value="spaceshipsim.SpaceShipSim" />
|
|
|
|
<target name="clean" >
|
|
<delete dir="bin" />
|
|
</target>
|
|
|
|
<target name="compile" >
|
|
<mkdir dir="${classes.dir}" />
|
|
<javac srcdir="${src.dir}" destdir="${classes.dir}" />
|
|
</target>
|
|
|
|
<target name="jar" depends="compile" >
|
|
<mkdir dir="${jar.dir}" />
|
|
<jar destfile="${jar.dir}/${ant.project.name}.jar" basedir="${classes.dir}" >
|
|
<manifest>
|
|
<attribute name="Main-Class" value="${main-class}" />
|
|
</manifest>
|
|
</jar>
|
|
</target>
|
|
|
|
<target name="run" depends="jar" >
|
|
<java jar="${jar.dir}/${ant.project.name}.jar" fork="true" />
|
|
</target>
|
|
</project>
|