Bug Tracker

Ticket #3779: build.diff

File build.diff, 1.5 KB (added by cloudream, 11 years ago)
  • build.xml

     
    1818    <property description="Source Folder" name="SRC_DIR" value="src"  />
    1919    <property description="Files for parsing etc." name="BUILD_DIR" value="build" />
    2020    <property description="Rhino JS Engine" name="JAR" value="${BUILD_DIR}/js.jar" />
     21    <property description="YUICompressor" name="YUICompressor" value="${BUILD_DIR}/yuicompressor-2.4.2.jar" />
    2122
    2223    <property description="Folder for jquery, min, lite and packed target" name="DIST_DIR" value="./dist" />
    2324
     
    5455
    5556    <target name="min" depends="jquery" description="Remove all comments and whitespace, no compression, great in combination with GZip">
    5657        <echo message="Building ${JQ_MIN}" />
    57         <java jar="${JAR}" fork="true">
    58             <arg value="${BUILD_DIR}/build/min.js" />
    59             <arg value="${JQ}" />
    60             <arg value="${JQ_MIN}" />
    61         </java>
     58                <apply executable="java" parallel="false" verbose="true" dest="${DIST_DIR}">
     59                        <fileset dir="${DIST_DIR}">
     60                                <include name="jquery.js" />
     61                        </fileset>
     62                        <arg line="-jar" />
     63                        <arg path="${YUICompressor}" />
     64                        <arg value="--charset" />
     65                        <arg value="ANSI" />
     66                        <arg value="-o" />
     67                        <targetfile />
     68                        <mapper type="glob" from="jquery.js" to="jquery.min.js" />
     69                </apply>
    6270        <echo message="${JQ_MIN} built." />
    6371    </target>
    6472