forked from dtmilano/AndroidViewClient
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
69 lines (61 loc) · 2.13 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
<?xml version="1.0" encoding="UTF-8"?>
<project name="Culebra" default="deprecated">
<property file="ant.properties" />
<loadproperties srcFile="project.properties" />
<target name="deprecated">
<echo message="NOTICE:" />
<echo message="Jar file and monkeyrunner use are deprecated as of AndroidViewClient >= 4.0.0" />
</target>
<property name="versionRE" value="^\s*__version__\s*=\s*'(.*)'\s*$" />
<loadfile srcfile="src/com/dtmilano/android/viewclient.py"
property="avc.version">
<filterchain>
<linecontainsregexp>
<regexp pattern="${versionRE}" />
</linecontainsregexp>
<tokenfilter>
<replaceregex pattern="${versionRE}" replace="\1" />
</tokenfilter>
<striplinebreaks />
</filterchain>
</loadfile>
<property name="avc.jar" value="bin/${avc.jarname}-${avc.version}.jar" />
<target name="jar" depends="compile">
<echo message="Creating ${avc.jarname} ${avc.version} jar ..." />
<jar destfile="${avc.jar}">
<fileset dir="src/" excludes="**/*.java" />
<fileset dir="." includes="tools/*" />
<fileset dir="bin/classes" />
<manifest>
<attribute name="Main-Class"
value="com.dtmilano.android.viewclient.ViewClient" />
</manifest>
</jar>
</target>
<target name="clean">
<delete dir="bin" />
</target>
<target name="compile">
<mkdir dir="bin/classes" />
<javac srcdir="src" destdir="bin/classes" />
</target>
<target name="install" depends="jar,doc-jar">
<mkdir dir="${gdrive.bin.dest.dir}" />
<copy file="${avc.jar}" todir="${gdrive.bin.dest.dir}" />
<mkdir dir="${gdrive.doc.dest.dir}" />
<copy file="${avc.doc.jar}" todir="${gdrive.doc.dest.dir}" />
</target>
<target name="doc" >
<mkdir dir="docs" />
<exec executable="epydoc">
<arg value="--config=viewclient.epydoc" />
</exec>
</target>
<property name="avc.doc.jar" value="bin/${avc.doc.jarname}-${avc.version}.jar" />
<target name="doc-jar" depends="doc">
<echo message="Creating ${avc.doc.jarname} ${avc.version} jar ..." />
<jar destfile="${avc.doc.jar}">
<fileset dir="docs/" />
</jar>
</target>
</project>