comparison spring-ltw-ant.xml @ 61:0fe9ada37b0a

USASR-505: script to retrieve spring agent and add to run.jvmargs
author smith@nwoca.org
date Mon, 08 Aug 2011 14:56:33 -0400
parents
children a9d9befd8dd2
comparison
equal deleted inserted replaced
60:5bf585a38400 61:0fe9ada37b0a
1 <?xml version="1.0" encoding="UTF-8"?>
2 <project name="spring-ltw-ant" basedir="."
3 xmlns:ivy="antlib:fr.jayasoft.ivy.ant"
4 xmlns:ssdt="http://www.ssdt-ohio.org/ant/common"
5 xmlns:ssdtant="antlib:org.ssdt_ohio.tools.ant">
6
7
8 <ssdtant:add-dependency target="-pre-test-run" depends="-spring-ltw-init"/>
9 <ssdtant:add-dependency target="-pre-test-run-single" depends="-spring-ltw-init"/>
10 <ssdtant:add-dependency target="run-single" depends="-spring-ltw-init"/>
11 <ssdtant:add-dependency target="run-test-with-main" depends="-spring-ltw-init"/>
12 <ssdtant:add-dependency target="idea.prepare.test.run" depends="-spring-ltw-init"/>
13
14 <target name="-spring-ltw-init" depends="init,-spring-ltw-retrieve" unless="spring.ltw.disabled">
15
16 <var name="runmain.jvmargs.spring" value="${runmain.jvmargs}"/>
17 <var name="runmain.jvmargs" value="${spring.agent.arg} ${runmain.jvmargs.spring}"/>
18 <var name="runmain.jvmargs.spring" unset="true"/>
19
20 <var name="run.jvmargs.spring" value="${run.jvmargs}"/>
21 <var name="run.jvmargs" value="${spring.agent.arg} ${run.jvmargs.spring}"/>
22 <var name="run.jvmargs.spring" unset="true"/>
23 <echo message="enabled spring java agent: ${spring.agent.arg}"/>
24
25 </target>
26
27 <target name="-spring-ltw-retrieve" unless="spring.ltw.disabled">
28 <property name="spring.agent.org" value="org.springframework"/>
29 <property name="spring.agent.module" value="org.springframework.instrument"/>
30 <property name="spring.agent.revision" value="3.0.5.RELEASE"/>
31 <ivy:resolve resolveId="springagentid"
32 organisation="${spring.agent.org}"
33 module="${spring.agent.module}"
34 revision="${spring.agent.revision}"
35 type="jar"
36 inline="true"
37 keep="true"
38 log="quiet"/>
39 <ivy:retrieve
40 resolveid="springagentid"
41 pattern="${basedir}/${build.dir}/${lib.dir}/spring-agent.[ext]"
42 type="jar"
43 log="quiet"/>
44
45 <property name="spring.agent.arg" value="-javaagent:${build.dir}/${lib.dir}/spring-agent.jar"/>
46 </target>
47
48
49
50 </project>