-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
161 lines (138 loc) · 4.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
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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
<?xml version="1.0" ?>
<project name="LuaJPlugin" default="package" basedir=".">
<!--
conditional on the operating system
https://alvinalexander.com/blog/post/java/how-conditional-operation-ant-script-operating-system
-->
<!-- <echo message="${os.name}" /> -->
<condition property="os.nickname" value="win">
<os family="windows" />
</condition>
<condition property="os.nickname" value="lin">
<os family="unix" />
</condition>
<condition property="os.nickname" value="mac">
<os family="mac" />
</condition>
<!-- <echo message="os nickname is ${os.nickname}"/> -->
<property file="build-${os.nickname}.properties" />
<!--
<property file="build.properties" />
<property file="../build.properties" />
-->
<property name="compiler.source" value="1.8" />
<property name="compiler.target" value="1.8" />
<property name="src.dir" value="src" />
<!-- the directory for the compiled classes. Files in this directory
will be included in the finished jar file. -->
<property name="classes.dir" location="classes" />
<!-- class name for 'main' to run as application -->
<property name="main.class" value="luaj.LuaJPlugin"/>
<!-- Documentation process
none: if you supply your own html file as this template does.
xsltproc: if you plan on using docbook
-->
<property name="docs-proc.target" value="xsltproc" />
<property name="plugin.version" value="1.1" />
<!-- jEdit installation properties. -->
<!-- already defined in build.properties:
<property name="build.support" value="build-support" />
-->
<import file="${build.support}/plugin-build.xml" />
<!-- custom: -->
<property name="jedit.plugins.dir" value="${jedit.install.dir}/jars"/>
<property name="jedit.user.plugins.dir" value="${jedit.user.home}/jars"/>
<!--
This selector defines the files that will be
compiled by the "compile" target. Define here which
files under ${src.dir} will be compiled when the
"compile" task is called.
<selector id="compileFiles">
<filename name="*.java" />
</selector>
-->
<!-- If you want any extra files to be included with your plugin's jar,
such as custom images, you need to specify them here. -->
<selector id="packageFiles">
<and>
<or>
<filename name="luaj/bsh/*.bsh" />
<filename name="luaj/commands/*.xml" />
</or>
</and>
</selector>
<!--
<selector id="docsFiles">
<and>
<filename name="*.xml" />
</and>
</selector>
-->
<selector id="extraFiles">
<and>
<or>
<filename name="*.props" />
<filename name="*.xml" />
</or>
<not>
<filename name="build.xml" />
</not>
</and>
</selector>
<!-- Add your plugin's specific dependencies here -->
<path id="project.class.path">
<!-- Dependencies that are bundled with your plugin.
These should also be represented in your props file under the,
"plugin.[plugin class].jars" property. -->
<!-- <pathelement path="lib/dependency.jar" /> -->
<pathelement path="lib/luaj-jse-3.0.1.jar" />
<!-- Dependencies that are supplied by other plugins. -->
<!-- <pathelement path="${jedit.plugins.dir}/dependency.jar" /> -->
<pathelement path="${jedit.plugins.dir}/Console.jar" />
<pathelement path="${jedit.plugins.dir}/Classpath.jar" />
</path>
<target name="build.prepare">
<!-- Copy over required dependencies to install.dir -->
<copy todir="${install.dir}">
<fileset dir="lib">
<filename name="*.jar"/>
</fileset>
</copy>
</target>
<!-- =====================================
Builds the plugin JAR file (inluding docs)
====================================== -->
<!--
<target name="build"
depends="build.prepare,compile"
description="Builds the plugin JAR file (no docs)">
<mkdir dir="${build.classes}" />
<delete dir="${build.docs}" failonerror="false" />
<mkdir dir="${build.docs}" />
<delete dir="${build.extras}" failonerror="false" />
<mkdir dir="${build.extras}" />
<mkdir dir="${install.dir}" />
<copy todir="${build.docs}" includeEmptyDirs="false">
<fileset dir="${basedir}/docs">
<selector refid="docsFiles" />
</fileset>
</copy>
<copy todir="${build.extras}" includeEmptyDirs="false">
<fileset dir="${basedir}">
<selector refid="extraFiles" />
</fileset>
</copy>
<jar jarfile="${install.dir}/${jar.file}">
<fileset dir="${build.classes}" />
<fileset dir="${build.docs}" />
<fileset dir="${build.extras}" />
</jar>
<antcall target="build.post" />
</target>
-->
</project>
<!-- ::mode=xml:: -->
<!--
d:\tools\apache-ant-1.9.7\bin\ant.bat
d:\tools\apache-ant-1.10.3\bin\ant.bat
-->