Repository navigation
Expand file tree
/
Copy pathbuild.xml
More file actions
61 lines (52 loc) · 1.92 KB
/
Copy pathbuild.xml
File metadata and controls
61 lines (52 loc) · 1.92 KB
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
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<project default="ci" name="JBench">
<property file="build.properties" />
<property file="build-sample.properties" />
<property file="${user.home}/user.properties" />
<path id="compiletime-deps">
<pathelement path="./lib/postgres/postgresql-42.7.3.jar"/>
</path>
<target name="ci" description="ci">
<mkdir dir="target/classes"/>
<delete>
<fileset dir="target/classes" includes="**" />
</delete>
<javac srcdir="src/main"
destdir="target/classes"
classpathref="compiletime-deps"
source="17"
target="17"
debug="on" encoding="UTF-8"
optimize="on"
includeAntRuntime="false"/>
<copy todir="target/classes">
<fileset dir="src/main" includes="**/*" excludes="**/package.html **/*.java"/>
</copy>
</target>
<target name="checkstyle" description="checkstyle">
<path id="execution.lib.path">
<fileset dir="./lib/checkstyle" includes="*.jar"/>
</path>
<!-- loading ant task -->
<taskdef name="checkstyle"
classname="com.puppycrawl.tools.checkstyle.ant.CheckstyleAntTask"
classpathref="execution.lib.path"
/>
<property name="severity" value="error"/>
<checkstyle config="checkstyle.xml"
maxWarnings="0"
failOnViolation="true" >
<fileset dir="src/main" includes="**/*.java"/>
<formatter type="plain"/>
</checkstyle>
</target>
<target name="dist" depends="ci" description="Builds jar">
<echo>Creating jar distribution</echo>
<!-- jar -->
<jar destfile="target/dist/jbench.jar"
basedir="target/classes"
includes="**"
manifest="src/mainfest/MANIFEST.MF" >
</jar>
</target>
</project>