monad / build.xml

<project name="monad" default="jar">

	<description>
		Build with "ant jar".
	</description>

	<property environment="env"/>

	<property name="src" location="src"/>
	<property name="build" location="classes"/>
	<property name="monad_jar" location="monad.jar"/>
	<property name="clojure.lib" location="${env.CLOJURE_LIB}"/>

	<path id="clojurelib">
		<fileset dir="${clojure.lib}" includes="**/*.jar"/>
	</path>

	<target name="init">
		<tstamp/>
		<mkdir dir="${build}"/>
	</target>

	<target name="aot" depends="init"
		description="Compile Clojure sources.">
		<java classname="clojure.lang.Compile">
			<classpath>
				<path location="${build}"/>
				<path location="${src}"/>
				<path refid="clojurelib"/>
			</classpath>
			<sysproperty key="clojure.compile.path"
				value="${build}"/>
			<arg value="de.kotka.monad"/>
			<arg value="de.kotka.monad.identity"/>
			<arg value="de.kotka.monad.maybe"/>
			<arg value="de.kotka.monad.state"/>
			<arg value="de.kotka.monad.error"/>
			<arg value="de.kotka.monad.reader"/>
		</java>
	</target>

	<target name="jar" depends="aot"
		description="Create jar file.">
		<jar jarfile="${monad_jar}">
			<path location="README.txt"/>
			<path location="LICENSE.txt"/>
			<fileset dir="${src}" includes="**/*.clj"/>
			<!-- Make sure, we don't include dependencies. -->
			<fileset dir="${build}" includes="de/kotka/**/*.class"/>
			<manifest>
				<attribute name="Class-Path" value="."/>
			</manifest>
		</jar>
	</target>

	<target name="clean"
		description="Remove autogenerated files and directories.">
		<delete dir="${build}"/>
		<delete file="${monad_jar}"/>
	</target>

</project>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.