forked from colorer/Colorer-schemes
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
105 lines (81 loc) · 3.14 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
100
101
102
103
104
105
<?xml version="1.0"?>
<project name="schemes" default="all" basedir=".">
<property name="target" value="all" description="default subproject target"/>
<property file='path.properties'/>
<target name='hrd'>
<ant antfile="build.xml" dir='${path.hrd}' target="${target}"/>
</target>
<target name='hrc'>
<ant antfile="build.xml" dir='${path.hrc}' target="${target}"/>
</target>
<target name='catalog'>
<copy file='catalog.xml_' tofile='${path.build-dir}/${path.base-dir}/catalog.xml' overwrite='true'/>
</target>
<target name='all' depends="catalog, hrc, hrd"/>
<target name="clean">
<antcall target='all'>
<param name='target' value='clean'/>
</antcall>
</target>
<target name='base'>
<antcall target="all"/>
</target>
<target name="base.pack" depends='base'>
<property name="base.pack_dir" value='${path.build-dir}/${path.base-pack}'/>
<antcall target='default.pack-dir'>
<param name='target-dir' value='${base.pack_dir}'/>
</antcall>
</target>
<target name="base.pack.clean">
<delete dir="${path.build-dir}/${path.base-pack}"/>
</target>
<target name="base.far" description='Builds a base dir for FarColorer'>
<property name="base.far_dir" value='${path.build-dir}/${path.base-far}'/>
<antcall target='default.pack-dir'>
<param name='target-dir' value='${base.far_dir}'/>
</antcall>
<copy file='hrc/hrc/CHANGELOG' todir='${base.far_dir}/hrc'/>
</target>
<target name="base.far.clean">
<delete dir="${path.build-dir}/${path.base-far}"/>
</target>
<target name="hrc.jar" depends='hrc'>
<mkdir dir='${target-dir}/hrc/auto/types'/>
<zip destfile='${target-dir}/hrc/common.jar'>
<fileset dir='${path.build-dir}/${path.base-dir}/hrc' includes='**/*' excludes='proto*.hrc, *.ent.hrc, auto, auto/**/*'/>
</zip>
<copy todir='${target-dir}/hrc/' overwrite='true'>
<fileset dir='${path.build-dir}/${path.base-dir}/hrc/' includes='proto*.hrc, *.ent.hrc'/>
</copy>
<copy todir='${target-dir}/hrc/' overwrite='true'>
<fileset dir='${path.build-dir}/${path.base-dir}/hrc/' includes='auto/**/*'/>
</copy>
<replace dir='${target-dir}/hrc/' includes='*.hrc' token='link="' value='link="jar:common.jar!'/>
</target>
<target name="base.hrd-copy" depends='hrd'>
<mkdir dir='${target-dir}/hrd'/>
<copy todir='${target-dir}/hrd/' overwrite='true'>
<fileset dir='${path.build-dir}/${path.base-dir}/hrd/' excludes='reg.addons/**'/>
</copy>
</target>
<target name="default.pack-dir">
<mkdir dir='${target-dir}'/>
<antcall target='hrc.jar'>
<param name='target-dir' value='${target-dir}'/>
</antcall>
<antcall target='base.hrd-copy'>
<param name='target-dir' value='${target-dir}'/>
</antcall>
<antcall target='catalog'/>
<copy file='${path.build-dir}/${path.base-dir}/catalog.xml' tofile='${target-dir}/catalog.xml' overwrite='true'/>
</target>
<target name="base.update" description='Builds a package of the current HRC base'>
<tstamp><format property="TODAY" pattern="yyyy-MM-dd"/></tstamp>
<property name='hrcupdate-zip' value='${path.build-dir}/colorer-base.${TODAY}.zip'/>
<antcall target='base.pack.clean'/>
<antcall target='base.pack'/>
<zip destfile='${hrcupdate-zip}'>
<fileset dir='${path.build-dir}/${path.base-dir}'/>
</zip>
</target>
</project>