-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.xml
67 lines (52 loc) · 2.82 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
<project xmlns:artifact="antlib:org.apache.maven.artifact.ant" name="cabalrunner-custom-build" default="dist"
basedir=".">
<property file="build.properties"/>
<property name="plugin.name" value="cabalRunner"/>
<property name="javac2.home" value="${basedir}/lib-compile"/>
<import file="teamcity-common.xml"/>
<import file="cabal-teamcity-plugin.xml"/>
<target name="package" depends="define.version">
<package.teamcity.plugin name="${plugin.name}"
common.output="${cabalrunner-common.output.dir}"
server.output="${cabalrunner-server.output.dir}"
agent.output="${cabalrunner-agent.output.dir}"
server.lib.dir="lib" server.lib.includes="*.jar"
plugin.descriptor.file="${basedir}/teamcity-plugin.xml"
plugin.version="${plugin.version}">
<agent-additional-files>
<fileset dir="${basedir}" id="agent-additional-files">
<include name="${cabalrunner-agent.relative.output.dir}/*.exe"></include>
<include name="${cabalrunner-agent.relative.output.dir}/*.config"></include>
<include name="lib/*.jar"/>
<exclude name="lib/*maven-ant-tasks*"/>
</fileset>
</agent-additional-files>
</package.teamcity.plugin>
</target>
<path id="maven-ant-tasks.classpath" path="misclib/maven-ant-tasks-2.1.3.jar"/>
<typedef resource="org/apache/maven/artifact/ant/antlib.xml"
uri="antlib:org.apache.maven.artifact.ant"
classpathref="maven-ant-tasks.classpath"/>
<target name="define.version" depends="define.version.if.under.teamcity">
<tstamp>
<format property="current.time" pattern="yyyyMMddHHmm"/>
</tstamp>
<property name="plugin.version" value="SNAPSHOT-${current.time}"/>
</target>
<target name="define.version.if.under.teamcity" if="build.number">
<property name="plugin.version" value="${build.number}"/>
</target>
<target name="dist" depends="check.teamcitydistribution,all,package"/>
<target name="clean" depends="cabalrunner.clean"/>
<target name="deploy" depends="dist">
<deploy.teamcity.plugin name="${plugin.name}"/>
</target>
<artifact:dependencies filesetId="dependency.fileset">
<dependency groupId="commons-io" artifactId="commons-io" version="2.1"/>
</artifact:dependencies>
<copy todir="${basedir}/lib">
<fileset refid="dependency.fileset"/>
<!-- This mapper strips off all leading directory information -->
<mapper type="flatten"/>
</copy>
</project>