forked from jenssegers-deprecated/Ghendetta
-
Notifications
You must be signed in to change notification settings - Fork 3
/
build.xml
99 lines (89 loc) · 2.85 KB
/
build.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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
<?xml version="1.0"?>
<project name="Ghendetta build script" default="initialize">
<!--
*************************************************
* PROPERTIES *
*************************************************
-->
<property name="css_dir" value="css" />
<property name="js_dir" value="js" />
<!--
*************************************************
* YUI COMPRESSOR *
*************************************************
-->
<target name="compress">
<java jar="tools/yuicompressor.jar" fork="true">
<arg value="${file}" />
<arg value="-o" />
<arg value="${file}" />
</java>
<echo>Minified: ${file}</echo>
</target>
<!--
*************************************************
* MAPBOX *
*************************************************
-->
<target name="concat_mapbox">
<concat destfile="${js_dir}/mapbox.min.js">
<filelist id="files" dir="${js_dir}">
<file name="mapbox/leaflet.js" />
<file name="mapbox/wax.js" />
<file name="mapbox.js" />
</filelist>
</concat>
</target>
<target name="compress_mapbox" depends="concat_mapbox">
<antcall target="compress">
<param name="file" value="${js_dir}/mapbox.min.js" />
</antcall>
</target>
<!--
*************************************************
* APPLICATION *
*************************************************
-->
<target name="concat_application">
<concat destfile="${js_dir}/application.min.js">
<filelist id="files" dir="${js_dir}">
<file name="application.js" />
</filelist>
</concat>
</target>
<target name="compress_application" depends="concat_application">
<antcall target="compress">
<param name="file" value="${js_dir}/application.min.js" />
</antcall>
</target>
<!--
*************************************************
* STYLESHEET *
*************************************************
-->
<target name="concat_stylesheet">
<concat destfile="${css_dir}/styles.min.css">
<filelist id="files" dir="${css_dir}">
<file name="styles.css" />
</filelist>
</concat>
</target>
<target name="compress_stylesheet" depends="concat_stylesheet">
<antcall target="compress">
<param name="file" value="${css_dir}/styles.min.css" />
</antcall>
</target>
<!--
*************************************************
* INITIALIZE *
*************************************************
-->
<target name="initialize">
<echo>-------------------------------------</echo>
<echo>Initialising Apache Ant</echo>
<antcall target="compress_mapbox" />
<antcall target="compress_application" />
<antcall target="compress_stylesheet" />
<echo>-------------------------------------</echo>
</target>
</project>