forked from wet-boew/wet-boew
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build-tasks.xml
59 lines (55 loc) · 2.79 KB
/
build-tasks.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<?xml version="1.0" encoding="UTF-8"?>
<project name="build-tasks" default="default" basedir=".">
<dirname property="tasks.basedir" file="${ant.file.build-tasks}"/>
<property file="${tasks.basedir}/build-tasks.properties"/>
<!-- ant contribs task definition -->
<path id="antcontrib.classpath">
<pathelement location="${antcontribs.jar}" />
</path>
<taskdef resource="net/sf/antcontrib/antlib.xml">
<classpath refid="antcontrib.classpath" />
</taskdef>
<!-- yui-compressor task definition -->
<path id="yui.classpath">
<pathelement location="${yui-compressor.jar}" />
<pathelement location="${yui-compressor-ant-task.jar}" />
</path>
<taskdef name="yui-compressor" classname="net.noha.tools.ant.yuicompressor.tasks.YuiCompressorTask">
<classpath refid="yui.classpath" />
</taskdef>
<!-- css embed Base64Encode images task definition -->
<path id="cssurlembed.classpath">
<pathelement location="${cssurlembed.jar}" />
</path>
<taskdef name="cssurlembed" classname="net.nczonline.web.cssembed.CSSEmbedTask">
<classpath refid="cssurlembed.classpath" />
</taskdef>
<!-- Include the compiled jruby.jar file -->
<path id="jruby.classpath">
<fileset dir="${lib.dir}">
<include name="jruby*.jar"/>
</fileset>
</path>
<!-- Include jruby + gems (compass + sass + zengrids) -->
<target name="-build-jruby" depends="-jruby.jar.check" unless="jruby.jar.exists">
<mkdir dir="${lib.dir}/jruby-compiled" />
<get src="http://jruby.org.s3.amazonaws.com/downloads/1.6.7.2/jruby-complete-1.6.7.2.jar" dest="${lib.dir}/jruby.jar"/>
<get src="http://production.cf.rubygems.org/gems/sass-3.1.19.gem" dest="${lib.dir}/jruby-compiled/sass.gem"/>
<get src="http://production.cf.rubygems.org/gems/chunky_png-1.2.5.gem" dest="${lib.dir}/jruby-compiled/chunky_png.gem"/>
<get src="http://production.cf.rubygems.org/gems/fssm-0.2.9.gem" dest="${lib.dir}/jruby-compiled/fssm.gem"/>
<get src="http://production.cf.rubygems.org/gems/compass-0.12.1.gem" dest="${lib.dir}/jruby-compiled/compass.gem"/>
<get src="http://production.cf.rubygems.org/gems/zen-grids-1.2.gem" dest="${lib.dir}/jruby-compiled/zen-grids.gem"/>
<java jar="${lib.dir}/jruby.jar" fork="true">
<arg line="-S gem install -i "${lib.dir}/vendors" "${lib.dir}/jruby-compiled/sass.gem" "${lib.dir}/jruby-compiled/chunky_png.gem" "${lib.dir}/jruby-compiled/fssm.gem" "${lib.dir}/jruby-compiled/compass.gem" "${lib.dir}/jruby-compiled/zen-grids.gem""/>
</java>
<exec executable="jar" dir="${lib.dir}/">
<arg line="-uf jruby.jar -C vendors ." />
</exec>
<delete dir="${lib.dir}/jruby-compiled" />
</target>
<target name="-jruby.jar.check">
<condition property="jruby.jar.exists">
<available file="${lib.dir}/jruby.jar" type="file"/>
</condition>
</target>
</project>