<project name="WebRaveler2" default="compile" basedir=".">
    <description>
	    Test ant file for building Web Raveler
    </description>

  <property name="build-dir" location="bin"/>

  <!-- Clean the build directory -->
  <target name="clean"
  	  description="remove the build directory">
      <delete dir="${build-dir}"/>
  </target>
  
  <!-- Make sure the build dir exists -->
  <target name="init"
  	  description="make sure the build directory exists">
      <mkdir dir="${build-dir}"/>
  </target>
  
  <!-- Compile the project into the build directory -->
  <target name="compile" 
  	  depends="init"
	  description="compile the project into the build directory" >
     <javac srcdir="src" destdir="bin">
         <classpath>
            <pathelement path="${build-dir}"/>
            <fileset dir="lib">
                <include name="*.jar"/>
            </fileset>
        </classpath>
    </javac>
  </target>    

  <!-- Run Web Raveler -->
  <target name="run"> <!-- depends="compile" -->
    <java classname="webraveler.ravel.Ravel" fork="true">
         <classpath>
            <pathelement path="${build-dir}"/>
            <fileset dir="lib">
                <include name="*.jar"/>
            </fileset>
        </classpath>
    </java>
  </target>
 
  <!-- Test the HTMLPage2 Class -->
  <target name="test" depends="compile">
    <java classname="webraveler.html.HTMLPage2" fork="true">
         <classpath>
            <pathelement path="${build-dir}"/>
            <fileset dir="lib">
                <include name="*.jar"/>
            </fileset>
        </classpath>
    </java>
  </target>
</project>
