-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
61 lines (53 loc) · 2.24 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
<project name="Report4s" default="main" basedir=".">
<property name="src.dir" location="src" />
<property name="build.dir" location="bin" />
<property name="temp.dir" location="temp" />
<property name="jar.dir" location="jar" />
<property name="lib.dir" location="lib" />
<property name="javadoc.dir" location="javadoc" />
<property name="assets.dir" location="assets" />
<property name="jarfile" value="report4s" />
<property name="version" value="5.2" />
<path id="classpath">
<fileset dir="${lib.dir}" includes="**/*.jar" />
</path>
<!-- Delete the existing build -->
<target name="clean">
<delete dir="${build.dir}" quiet="true" />
<delete dir="${javadoc.dir}" quiet="true" />
<delete dir="${temp.dir}" quiet="true" />
<delete dir="${jar.dir}" quiet="true" />
</target>
<!-- Create the necessary directories for a build -->
<target name="makedir">
<mkdir dir="${build.dir}" />
<mkdir dir="${javadoc.dir}" />
<mkdir dir="${jar.dir}" />
</target>
<!-- Compile the java code -->
<target name="compile" depends="clean, makedir">
<javac srcdir="${src.dir}" destdir="${build.dir}" classpathref="classpath" debug="true" includeantruntime="false" />
</target>
<!-- Generate the javadoc -->
<target name="javadoc">
<javadoc destdir="${javadoc.dir}" classpathref="classpath" sourcepath="${src.dir}"
public="true">
<link href="https://www.selenium.dev/selenium/docs/api/java/" />
<link href="https://javadoc.io/doc/org.testng/testng/7.8.0/" />
</javadoc>
</target>
<!-- Build the jar file -->
<target name="jar" depends="compile">
<mkdir dir="${temp.dir}" />
<copy todir="${temp.dir}/assets">
<fileset dir="${assets.dir}" />
</copy>
<jar destfile="${jar.dir}/${jarfile}-${version}.jar">
<fileset dir="${temp.dir}" />
<fileset dir="${build.dir}" />
<fileset file="LICENSE" />
</jar>
<delete dir="${temp.dir}" quiet="true" />
</target>
<target name="main" depends="jar" />
</project>