Skip to content

Instantly share code, notes, and snippets.

@ussy
Created April 15, 2011 09:30
Show Gist options
  • Save ussy/921458 to your computer and use it in GitHub Desktop.
Save ussy/921458 to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="UTF-8"?>
<project name="library" default="package">
<property name="jarname" location="./bin/${ant.project.name}.jar" />
<property name="src" location="./src" />
<property name="bin" location="./bin" />
<target name="clean">
<delete dir="${bin}" />
</target>
<target name="compile">
<delete dir="${bin}/*" />
<javac srcdir="${src}" destdir="${bin}" />
</target>
<target name="package" depends="compile">
<delete file="${jarname}" />
<jar jarfile="${jarname}">
<fileset dir="${bin}" />
</jar>
</target>
</project>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment