[3167df]: build.xml Maximize Restore History

Download this file

build.xml    83 lines (71 with data), 2.9 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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
<project name="PMDPlugin" default="dist" basedir=".">
<!-- user defined build properties, these override any properties set below -->
<property file="build.properties"/>
<property file="../build.properties"/>
<!-- properties specific to this build file -->
<property name="build" location="build"/>
<property name="src" location="src"/>
<property name="lib" location="lib"/>
<!-- default location of jEdit installation containing jedit.jar -->
<property name="jedit.install.dir" location="../.."/>
<!-- default location of user folder containing plugin jars -->
<property name="install.dir" location="${user.home}/.jedit/jars"/>
<property name="jedit.plugins.dir" location="${install.dir}"/>
<!-- set up the classpath for the build -->
<path id="project.class.path">
<pathelement location="${jedit.install.dir}/jedit.jar"/>
<pathelement location="${jedit.plugins.dir}/ErrorList.jar"/>
<pathelement location="${jedit.plugins.dir}/CommonControls.jar"/>
<pathelement location="${jedit.plugins.dir}/kappalayout.jar"/>
<pathelement location="${build}"/>
<fileset casesensitive="false" id="pmd.libs" dir="${lib}">
<include name="*.jar"/>
</fileset>
</path>
<!-- might be able to auto-reload the plugin -->
<condition property="can.reload.plugins">
<and>
<available classname="org.gjt.sp.jedit.jEdit"/>
<available classname="ReloadPluginTask"/>
</and>
</condition>
<!-- Target: clean - delete the build directory contents -->
<target name="clean">
<delete dir="${build}"/>
<mkdir dir="${build}"/>
</target>
<!-- Target: compile -->
<target name="compile">
<mkdir dir="${build}"/>
<javac
srcdir="${src}"
destdir="${build}"
source="1.5"
target="1.5"
debug="on"
deprecation="on">
<classpath refid="project.class.path"/>
</javac>
</target>
<!-- Target: jar - create the plugin -->
<target name="dist" depends="compile">
<jar jarfile="${install.dir}/${ant.project.name}.jar">
<fileset dir="${build}"/>
<fileset dir="${basedir}">
<include name="*.props"/>
<include name="*.xml"/>
<include name="*.html"/>
<include name="doc/*"/>
</fileset>
</jar>
<copy todir="${install.dir}">
<fileset refid="pmd.libs" />
</copy>
<antcall target="reload"/>
</target>
<target name="reload" if="can.reload.plugins">
<echo>Reloading ${install.dir}/${ant.project.name}.jar</echo>
<taskdef name="reloadPlugin" classname="ReloadPluginTask"/>
<reloadPlugin jarfile="${install.dir}/${ant.project.name}.jar"/>
</target>
</project>