-
Notifications
You must be signed in to change notification settings - Fork 9
/
build.xml
51 lines (39 loc) · 1.44 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
<project name="ublab-bot" default="main" basedir=".">
<description>
ublab-bot (JAR) with Ant build script
</description>
<property name="ublab-bot" value="DateUtils" />
<!-- Java sources -->
<property name="src.dir" location="src" />
<!-- Java classes -->
<property name="build.dir" location="bin" />
<!-- Output, Jar -->
<property name="dist.dir" location="dist" />
<target name="init">
<!-- Create the time stamp -->
<tstamp />
<!-- Create the build directory structure used by compile -->
<mkdir dir="${build.dir}" />
</target>
<target name="compile" depends="init" description="compile the source ">
<!-- Compile the java code from ${src.dir} into ${build.dir} -->
<javac includeantruntime="false" srcdir="${src.dir}" destdir="${build.dir}" />
</target>
<target name="dist" depends="compile" description="package, output to JAR">
<!-- Create the distribution directory -->
<mkdir dir="${dist.dir}" />
<!-- Put everything in ${build} into the {$projectName}-${DSTAMP}.jar file -->
<jar jarfile="${dist.dir}/${projectName}-${DSTAMP}.jar" basedir="${build.dir}" >
<manifest>
<!-- create an executable Jar -->
<attribute name="App" value="org.ublab.bot" />
</manifest>
</jar>
</target>
<target name="clean" description="clean up">
<delete dir="${build.dir}" />
<delete dir="${dist.dir}" />
</target>
<!-- Default, run this -->
<target name="main" depends="clean, compile, dist" />
</project>