<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE project>
<project name="jquery.fullscreen" default="package">

  <taskdef name="jscomp"
           classname="com.google.javascript.jscomp.ant.CompileTask"
           classpath="lib/compiler.jar" />
           
  <target name="compile">
    <delete file="jquery.fullscreen-min.js" />
    <jscomp compilationLevel="advanced"
            warning="verbose"
            debug="false"
            output="jquery.fullscreen-min.js">
      <sources dir=".">
        <file name="jquery.fullscreen.js" />
      </sources>
      <externs dir="externs">
        <file name="jquery.js" />
      </externs>
    </jscomp>
  </target>
  
  <target name="test" depends="compile">
  </target>
  
  <target name="package" depends="test">
    <jar destfile="jquery.fullscreen.jar">
      <mappedresources>
        <fileset dir=".">
          <include name="jquery.fullscreen.js" />
        </fileset>
        <globmapper from="*" to="script-sources/*" />
      </mappedresources>
      <mappedresources>
        <fileset dir=".">
          <include name="jquery.fullscreen-min.js" />
        </fileset>
        <globmapper from="*-min.js" to="scripts/*.js" />
      </mappedresources>
      <mappedresources>
        <fileset dir="externs">
          <include name="jquery.fullscreen.js" />
        </fileset>
        <globmapper from="*" to="script-externs/*" />
      </mappedresources>
    </jar>
  </target>
  
  <target name="clean">
    <delete file="jquery.fullscreen.jar" />
  </target>

</project>