Skip to content

Instantly share code, notes, and snippets.

/build.xml Secret

Created Nov 26, 2013
Embed
What would you like to do?
<?xml version="1.0" encoding="UTF-8"?>
<project name="PetClinic" default="war" xmlns:ivy="antlib:org.apache.ivy.ant">
<property name="src" location="src/main/java" />
<property name="resources" location="src/main/resources" />
<property name="webapp" location="src/main/webapp" />
<property name="test.src" location="src/test/java" />
<property name="target" location="target" />
<property name="classes" location="${target}/classes" />
<property name="test.classes" location="${target}/test-classes" />
<property name="test.report" location="${target}/test-report" />
<target name="build" description="Compile everything">
<mkdir dir="${classes}" />
<ivy:cachepath pathid="ivy.path" />
<javac srcdir="${src}" destdir="${classes}"
classpathref="ivy.path" includeantruntime="false" />
</target>
<target name="war" depends="build" description="Package into war file">
<ivy:cachepath pathid="ivy.runtime.path" conf="runtime" />
<war destfile="${target}/petclinic.war" webxml="${webapp}/WEB-INF/web.xml">
<classes dir="${classes}"/>
<classes dir="${resources}"/>
<fileset dir="${webapp}" />
<mappedresources>
<restrict>
<path refid="ivy.runtime.path"/>
<type type="file"/>
</restrict>
<chainedmapper>
<flattenmapper/>
<globmapper from="*" to="WEB-INF/lib/*"/>
</chainedmapper>
</mappedresources>
</war>
</target>
<target name="clean" description="Delete target">
<delete dir="${target}"/>
</target>
<target name="test" depends="build" description="Run JUnit tests">
<ivy:cachepath pathid="ivy.test.path" conf="test,provided" />
<mkdir dir="${test.report}" />
<mkdir dir="${test.classes}" />
<javac srcdir="${test.src}" destdir="${test.classes}"
classpathref="ivy.test.path" classpath="${classes}"
includeantruntime="false" />
<junit printsummary="yes" haltonfailure="no">
<classpath refid="ivy.test.path"/>
<classpath path="${resources}"/>
<classpath path="${test.src}"/>
<classpath path="${classes}"/>
<classpath path="${test.classes}"/>
<formatter type="plain"/>
<batchtest fork="yes" todir="${test.report}">
<fileset dir="${test.src}">
<include name="**/*Test*.java"/>
</fileset>
</batchtest>
</junit>
</target>
</project>
<?xml version="1.0" encoding="UTF-8"?>
<ivy-module version="2.0">
<info organisation="org.springframework.samples" module="spring-petclinic" revision="1.0.0-SNAPSHOT" />
<configurations>
<conf name="compile" />
<conf name="provided" />
<conf name="runtime" extends="compile" />
<conf name="test" extends="runtime" />
<conf name="default" extends="runtime" />
</configurations>
<dependencies>
<!-- Test dependencies -->
<dependency org="junit" name="junit" rev="4.11" conf="test->default(*)"/>
<dependency org="org.hamcrest" name="hamcrest-library" rev="1.3" conf="test->default(*)"/>
<dependency org="org.springframework" name="spring-test" rev="3.2.5.RELEASE" conf="test->default(*)"/>
<!-- Compile dependencies -->
<dependency org="org.jadira.usertype" name="usertype.core" rev="3.1.0.CR8" conf="compile->default(*)"/>
<dependency org="javax.servlet" name="jstl" rev="1.2" conf="compile->default(*)"/>
<dependency org="org.springframework.data" name="spring-data-jpa" rev="1.4.2.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-jdbc" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-aop" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-webmvc" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-tx" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-context-support" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-orm" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.springframework" name="spring-oxm" rev="3.2.5.RELEASE" conf="compile->default(*)">
<exclude org="commons-lang" module="commons-lang" name="*" type="*" ext="*" conf="" matcher="exact"/>
</dependency>
<dependency org="org.springframework" name="spring-jms" rev="3.2.5.RELEASE" conf="compile->default(*)"/>
<dependency org="org.slf4j" name="slf4j-api" rev="1.7.5" conf="compile->default(*)"/>
<dependency org="rome" name="rome" rev="1.0" conf="compile->default(*)"/>
<dependency org="joda-time" name="joda-time" rev="2.3" conf="compile->default(*)"/>
<dependency org="joda-time" name="joda-time-hibernate" rev="1.3" conf="compile->default(*)"/>
<dependency org="joda-time" name="joda-time-jsptags" rev="1.1.1" conf="compile->default(*)"/>
<dependency org="org.hibernate" name="hibernate-entitymanager" rev="4.2.1.Final" conf="compile->default(*)"/>
<dependency org="org.hibernate" name="hibernate-validator" rev="4.3.1.Final" conf="compile->default(*)"/>
<dependency org="org.hibernate" name="hibernate-ehcache" rev="4.2.1.Final" conf="compile->default(*)"/>
<dependency org="net.sf.ehcache" name="ehcache-core" rev="2.6.6" conf="compile->default(*)">
<exclude org="commons-logging" module="commons-logging" name="*" type="*" ext="*" conf="" matcher="exact"/>
</dependency>
<dependency org="org.webjars" name="bootstrap" rev="2.3.0" conf="compile->default(*)"/>
<dependency org="org.webjars" name="jquery-ui" rev="1.10.3" conf="compile->default(*)"/>
<dependency org="org.webjars" name="jquery" rev="2.0.3-1" conf="compile->default(*)"/>
<dependency org="org.aspectj" name="aspectjrt" rev="1.7.4" conf="compile->default(*)"/>
<dependency org="com.github.dandelion" name="datatables-jsp" rev="0.9.2" conf="compile->default(*)"/>
<dependency org="com.github.dandelion" name="datatables-export-itext" rev="0.9.2" conf="compile->default(*)"/>
<dependency org="com.github.dandelion" name="datatables-servlet2" rev="0.9.2" conf="compile->default(*)"/>
<!-- Runtime dependencies -->
<dependency org="org.apache.tomcat" name="tomcat-jdbc" rev="7.0.42" conf="runtime->default(*)"/>
<dependency org="ch.qos.logback" name="logback-classic" rev="1.0.13" conf="runtime->default(*)"/>
<dependency org="org.hsqldb" name="hsqldb" rev="2.3.1" conf="runtime->default(*)"/>
<dependency org="org.aspectj" name="aspectjweaver" rev="1.7.4" conf="runtime->default(*)"/>
<!-- Provided dependencies -->
<dependency org="javax.servlet" name="servlet-api" rev="2.5" conf="provided->default(*)"/>
<dependency org="javax.servlet.jsp" name="jsp-api" rev="2.2" conf="provided->default(*)"/>
<dependency org="com.sun.xml.bind" name="jaxb-impl" rev="2.2.7" conf="provided->default(*)"/>
<!-- Dependency overrides -->
<override org="org.springframework" module="spring-core" matcher="exact" rev="3.2.5.RELEASE"/>
<override org="org.springframework" module="spring-beans" matcher="exact" rev="3.2.5.RELEASE"/>
<override org="org.springframework" module="spring-context" matcher="exact" rev="3.2.5.RELEASE"/>
<override org="org.springframework" module="spring-orm" matcher="exact" rev="3.2.5.RELEASE"/>
<override org="org.springframework" module="spring-aop" matcher="exact" rev="3.2.5.RELEASE"/>
<override org="org.springframework" module="spring-tx" matcher="exact" rev="3.2.5.RELEASE"/>
</dependencies>
</ivy-module>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment