blob: 9971cd3fdf5f942c3f5f138bce32935a729848ae [file] [log] [blame]
<project
xmlns:j="jelly:core"
xmlns:u="jelly:util"
xmlns:ant="jelly:ant"
xmlns:maven="jelly:maven">
<postGoal name="xdoc:jelly-transform" >
<!-- replace maven stylesheets with wicket-stuff stylesheet -->
<ant:delete>
<fileset dir="${maven.build.dir}/docs/style"
includes="**/maven*.css"/>
</ant:delete>
<ant:copy todir="${maven.build.dir}/docs/style">
<fileset dir="${maven.multiproject.basedir}/wicket-stuff/xdocs/style">
<include name="**/*"/>
</fileset>
</ant:copy>
</postGoal>
<goal name="dist:build-src" />
<postGoal name="dist:prepare-bin-filesystem" >
<ant:mkdir dir="${maven.dist.bin.assembly.dir}/lib" />
<attainGoal name="eclipse-classpath"/>
<attainGoal name="idea-classpath"/>
<attainGoal name="tomcat-plugin"/>
<j:forEach var="lib" items="${pom.artifacts}">
<j:set var="dep" value="${lib.dependency}" />
<j:if test="${dep.type=='jar'}">
<j:choose>
<j:when test="${dep.getProperty('endorsed')}">
<ant:copy
todir="${maven.dist.bin.assembly.dir}/lib/endorsed"
file="${lib.path}" />
</j:when>
<j:otherwise>
<ant:copy todir="${maven.dist.bin.assembly.dir}/lib"
file="${lib.path}" />
</j:otherwise>
</j:choose>
</j:if>
</j:forEach>
<ant:copy todir="${maven.dist.bin.assembly.dir}/src/main/java">
<fileset dir="src/main/java">
<include name="**/*"/>
</fileset>
</ant:copy>
<ant:copy todir="${maven.dist.bin.assembly.dir}/src/webapp">
<fileset dir="src/webapp">
<include name="**/*"/>
</fileset>
</ant:copy>
<ant:copy todir="${maven.dist.bin.assembly.dir}" file="src/main/resources/build.xml" />
<ant:copy todir="${maven.dist.bin.assembly.dir}" file="src/main/resources/.project" />
<ant:copy todir="${maven.dist.bin.assembly.dir}/src/main/resources" file="src/main/resources/jetty-config.xml" />
<ant:delete>
<fileset dir="${maven.dist.bin.assembly.dir}/src/main/resources" excludes="jetty-config.xml"/>
<fileset dir="${maven.dist.bin.assembly.dir}" includes="*.xml"/>
<fileset dir="${maven.dist.bin.assembly.dir}" includes="*.properties"/>
<fileset dir="${maven.dist.bin.assembly.dir}" includes="*.jar"/>
</ant:delete>
<ant:copy todir="${maven.dist.bin.assembly.dir}" file="src/main/resources/build.xml" />
<ant:copy todir="${maven.dist.bin.assembly.dir}" file="project.xml" />
</postGoal>
<goal name="eclipse-classpath" description="Generates the dependencies for Eclipse">
<ant:echo>[ECLIPSE] Creating ${maven.dist.bin.assembly.dir}/.classpath ...</ant:echo>
<j:file name="${maven.dist.bin.assembly.dir}/.classpath" prettyPrint="true" outputMode="xml" xmlns="dummy">
<j:import file="src/main/resources/eclipse-classpath.xml" inherit="true"/>
</j:file>
</goal>
<goal name="idea-classpath" description="Generates the dependencies for IDEA">
<ant:echo>[IDEA] Creating ${maven.dist.bin.assembly.dir}/wicket-quickstart.iml ...</ant:echo>
<j:file name="${maven.dist.bin.assembly.dir}/wicket-quickstart.iml" prettyPrint="true" outputMode="xml" xmlns="dummy">
<j:import file="src/main/resources/wicket-quickstart.iml.xml" inherit="true"/>
</j:file>
<ant:echo>[IDEA] Creating ${maven.dist.bin.assembly.dir}/wicket-quickstart.ipr ...</ant:echo>
<j:file name="${maven.dist.bin.assembly.dir}/wicket-quickstart.ipr" prettyPrint="true" outputMode="xml" xmlns="dummy">
<j:import file="src/main/resources/wicket-quickstart.ipr.xml" inherit="true"/>
</j:file>
</goal>
<goal name="tomcat-plugin" description="Generates a tomcat plugin file">
<ant:echo>[TOMCAT] Creating ${maven.dist.bin.assembly.dir}/.tomcatplugin ...</ant:echo>
<j:file name="${maven.dist.bin.assembly.dir}/.tomcatplugin" prettyPrint="false" trim="true" outputMode="xml" xmlns="dummy">
<j:import file="src/main/resources/tomcatplugin.xml" inherit="true" />
</j:file>
</goal>
</project>