Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 5b8d89951c
Fetching contributors…

Cannot retrieve contributors at this time

83 lines (71 sloc) 2.721 kb
<project name="format" default="jar">
<description>
Build a jar that is the common lisp format library
</description>
<property name="build" location="classes"/>
<property name="clojure-jar" location="../clojure/clojure.jar"/>
<property name="unit-jar" location="../unit_test/unit-test.jar"/>
<!-- The JAR file to create. -->
<property name="jarfile" value="cl-format.jar"/>
<property name="releasedir" value="release/"/>
<target name="init">
<mkdir dir="${build}"/>
</target>
<target name="clean"
description="Remove generated files and directories.">
<delete file="${jarfile}"/>
<delete dir="${build}"/>
</target>
<target name="jar" depends="compile_classes"
description="Create jar file.">
<jar jarfile="${jarfile}">
<fileset dir="." includes="epl-v10.html"/>
<fileset dir="." includes="com/infolace/format.clj"/>
<fileset dir="." includes="com/infolace/format_base.clj"/>
<fileset dir="." includes="com/infolace/pprint.clj"/>
<fileset dir="." includes="com/infolace/dispatch.clj"/>
<fileset dir="." includes="com/infolace/format/utilities.clj"/>
<fileset dir="classes" includes="**/*.class"/>
</jar>
</target>
<target name="compile_classes" depends="init"
description="Compile clojure classes.">
<java classname="clojure.lang.Compile"
classpath=".:${build}:${clojure-jar}">
<sysproperty key="clojure.compile.path" value="${build}"/>
<arg value="com.infolace.format.ColumnWriter"/>
<arg value="com.infolace.format.PrettyWriter"/>
</java>
</target>
<target name="release" depends="jar"
description="Checks in the current jar file and tags the resulting checkin with a version number (use with -Dtagname=vX.Y.Z)">
<move file="${jarfile}" todir="${releasedir}"/>
<exec executable="git">
<arg value="add"/>
<arg value="-f"/>
<arg value="${releasedir}${jarfile}"/>
</exec>
<exec executable="git">
<arg value="commit"/>
<arg value="-m"/>
<arg value="Release ${tagname}"/>
</exec>
<exec executable="git">
<arg value="tag"/>
<arg value="-m"/>
<arg value="Making a release tag"/>
<arg value="${tagname}"/>
</exec>
</target>
<target name="run-tests" depends="jar"
description="Run all the unit tests">
<java classname="unit_test.run_tests" classpath="${clojure-jar}:${unit-jar}:${jarfile}:."
fork="true" failonerror="true">
<arg value="com.infolace.format.test.base"/>
</java>
<java classname="unit_test.run_tests" classpath="${clojure-jar}:${unit-jar}:${jarfile}:."
fork="true" failonerror="true">
<arg value="com.infolace.format.test.pretty"/>
</java>
</target>
</project>
Jump to Line
Something went wrong with that request. Please try again.