diff options
author | Ugnich Anton | 2012-10-23 01:44:58 +0700 |
---|---|---|
committer | Ugnich Anton | 2012-10-23 01:44:58 +0700 |
commit | 9b94011a09685dec1b1b38fef8294c6ffa578079 (patch) | |
tree | ab6808f9f10a29628d9bb93905b1fcd3c2887b43 /build.xml | |
parent | adfc38138808eede6bcc29a706c9191e7d2d84fe (diff) |
JS/CSS optimization
Diffstat (limited to 'build.xml')
-rw-r--r-- | build.xml | 23 |
1 files changed, 23 insertions, 0 deletions
@@ -10,6 +10,29 @@ <project name="com.juick.http.www" default="default" basedir="."> <description>Builds, tests, and runs the project com.juick.http.www.</description> <import file="nbproject/build-impl.xml"/> + + <target name="-pre-dist"> + <echo level="info" message="Compressing JavaScript and CSS files...." /> + <path id="yuicompressor.classpath"> + <fileset dir="${ant.home}/lib"> + <include name="yuiant.jar"/> + <include name="yuicompressor-2.4.7.jar"/> + </fileset> + </path> + <taskdef name="yuicompress" classname="com.yahoo.platform.yui.compressor.YUICompressTask"> + <classpath> + <path refid="yuicompressor.classpath"/> + </classpath> + </taskdef> + <yuicompress linebreak="8000" warn="false" munge="yes" preserveallsemicolons="true" outputfolder="${basedir}/${build.web.dir}"> + <fileset dir="${basedir}/web"> + <include name="**/*.js" /> + <include name="**/*.css" /> + </fileset> + </yuicompress> + <echo level="info" message="Compression Complete" /> + </target> + <!-- There exist several targets which are by default empty and which can be |