-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
54 lines (48 loc) · 2.12 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
<project name="MooreaLabBench" default="create-plugin" basedir=".">
<import file="shared.xml"/>
<property name="version-regex-pattern" value=".*PLUGIN_VERSION\s+=\s+"(\d+\.\d+\.\d+)";.*"/>
<loadfile property="plugin.version" srcfile="${shared.basedir}/src/com/biomatters/plugins/biocode/BiocodePlugin.java">
<filterchain>
<linecontainsregexp>
<regexp pattern="${version-regex-pattern}"/>
</linecontainsregexp>
<replaceregex pattern="${version-regex-pattern}" replace="\1"/>
<replacestring from="." to="_"/>
<striplinebreaks/>
</filterchain>
</loadfile>
<property name="plugin-name" value="com.biomatters.plugins.biocode.BiocodePlugin"/>
<property name="short-plugin-name" value="Biocode_${plugin.version}"/>
<target name="create-plugin" depends="clean,prepare,build-plugin">
<zip zipfile="${build}/${short-plugin-name}.gplugin">
<fileset dir="${build}">
<include name="${plugin-name}/**/*"/>
</fileset>
</zip>
</target>
<target name="build-plugin" depends="compile">
<jar jarfile="${build}/${plugin-name}.jar">
<fileset dir="${classes}"/>
</jar>
<mkdir dir="${build}/${plugin-name}"/>
<copy todir="${build}/${plugin-name}">
<fileset dir="${build}">
<include name="${plugin-name}.jar"/>
</fileset>
<fileset dir="${lib}">
<include name="*.jar"/>
<!-- Exclude Javadoc and sources from build -->
<exclude name="*-sources.jar"/>
<exclude name="*-javadoc.jar"/>
<!-- Exclude the Geneious Public API libraries because they are available at runtime -->
<exclude name="GeneiousPublicAPI*.jar"/>
<exclude name="jdom*.jar"/>
<exclude name="jebl*.jar"/>
</fileset>
<fileset dir="${resources}"/>
<fileset dir="${doc}">
<include name="readme.html"/>
</fileset>
</copy>
</target>
</project>