Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
44 lines (36 sloc) 1.62 KB
<?xml version="1.0" encoding="UTF-8"?>
<project name="Fjant" basedir="." default="jar">
<property name="src.dir" value="src" />
<property name="bin.dir" value="bin" />
<property name="classes.dir" value="classes" />
<target name="clean" description="Delete all generated files">
<delete dir="${classes.dir}" />
<delete file="${ant.project.name}.jar" />
</target>
<target name="compile" description="Compiles the Task">
<mkdir dir="${classes.dir}" />
<javac srcdir="${src.dir}" destdir="${classes.dir}" />
</target>
<target name="jar" description="JARs the Task" depends="compile">
<jar destfile="${bin.dir}/${ant.project.name}.jar" basedir="${classes.dir}" />
</target>
<target name="test.list" depends="jar">
<taskdef name="fjant" classname="com.linusu.${ant.project.name}" classpath="${bin.dir}/${ant.project.name}.jar"/>
<touch file="test/test1.css" />
<fjant output="test.css">
<filelist dir="test">
<file name="test1.css" />
<file name="test2.css" />
<file name="test3.css" />
</filelist>
</fjant>
</target>
<target name="test.set" depends="jar">
<taskdef name="fjant" classname="com.linusu.${ant.project.name}" classpath="${bin.dir}/${ant.project.name}.jar"/>
<touch file="test/test1.css" />
<fjant output="test.css">
<fileset dir="test" includes="*.css" />
</fjant>
</target>
<target name="test" description="Test the Task" depends="test.list, test.set" />
</project>