git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@112985 13f79535-47bb-0310-9956-ffa450edef68
118 lines
3.4 KiB
XML
118 lines
3.4 KiB
XML
<?xml version="1.0"?>
|
|
|
|
<project
|
|
xmlns:j="jelly:core"
|
|
xmlns:define="jelly:define"
|
|
xmlns:doc="doc"
|
|
xmlns:util="jelly:util"
|
|
xmlns:jxr="jxr">
|
|
|
|
<goal name="maven-jxr-plugin:register">
|
|
<j:if test="${sourcesPresent}">
|
|
<doc:registerReport
|
|
name="Source Xref"
|
|
pluginName="maven-jxr-plugin"
|
|
link="xref/index"
|
|
description="A set of browsable cross-referenced sources."/>
|
|
<j:if test="${unitTestSourcesPresent}">
|
|
<doc:registerReport
|
|
name="Test Xref"
|
|
pluginName="maven-jxr-plugin"
|
|
link="xref-test/index"
|
|
description="A set of browsable cross-referenced test sources."/>
|
|
</j:if>
|
|
</j:if>
|
|
</goal>
|
|
|
|
<goal name="maven-jxr-plugin:deregister">
|
|
<doc:deregisterReport name="Source Xref"/>
|
|
<doc:deregisterReport name="Test Xref"/>
|
|
</goal>
|
|
|
|
<define:taglib uri="jxr">
|
|
<define:jellybean
|
|
name="jxr"
|
|
className="org.apache.maven.jxr.JxrBean"
|
|
method="xref"
|
|
/>
|
|
</define:taglib>
|
|
|
|
<!-- ================================================================== -->
|
|
<!-- C R O S S R E F E R E N C E S O U R C E S -->
|
|
<!-- ================================================================== -->
|
|
|
|
<!-- Should we deprecate it to use only 'jxr' ? -->
|
|
<goal
|
|
name="maven-jxr-plugin:report"
|
|
description="Generate HTML cross reference sources">
|
|
|
|
<j:if test="${sourcesPresent == 'true'}">
|
|
|
|
<mkdir dir="${maven.jxr.destdir}"/>
|
|
|
|
<!-- If the 'startDir' attribute changes we need to update
|
|
CodeTransform.java in o.a.m.jxr, this will be fixed. -->
|
|
|
|
<echo>${maven.sourcesPresent}</echo>
|
|
|
|
<j:set var="javadocDestdir"
|
|
value="${pom.getPluginContext('maven-javadoc-plugin').getVariable('maven.javadoc.destdir')}"/>
|
|
|
|
<property
|
|
name="copyright"
|
|
value="Copyright &copy; ${year} ${pom.organization.name}. All Rights Reserved."
|
|
/>
|
|
|
|
<property
|
|
name="title"
|
|
value="${pom.name} ${pom.currentVersion} Reference"
|
|
/>
|
|
|
|
<copy file="${maven.jxr.stylesheet}"
|
|
tofile="${maven.jxr.destdir}/stylesheet.css"/>
|
|
|
|
<!-- XXX This is a dirty hack until the semantics of pom.build.sourceDirectory are cleared up -->
|
|
<j:set var="sourceDir" value="${pom.build.sourceDirectory}"/>
|
|
<util:file var="sourceDirFile" name="${sourceDir}"/>
|
|
|
|
<j:if test="${!sourceDirFile.isAbsolute()}">
|
|
<j:set var="sourceDir" value="${basedir}/${sourceDir}"/>
|
|
</j:if>
|
|
|
|
<jxr:jxr
|
|
sourceDir="${sourceDir}"
|
|
destDir="${maven.jxr.destdir}"
|
|
templateDir="${maven.jxr.templateDir}"
|
|
javadocDir="${javadocDestdir}"
|
|
windowTitle="${title}"
|
|
docTitle="${title}"
|
|
bottom="${copyright}">
|
|
</jxr:jxr>
|
|
|
|
<j:if test="${unitTestSourcesPresent == 'true'}">
|
|
<mkdir dir="${maven.jxr.destdir.test}"/>
|
|
<j:set var="testSourceDir" value="${pom.build.unitTestSourceDirectory}"/>
|
|
<util:file var="testSourceDirFile" name="${testSourceDir}"/>
|
|
|
|
<j:if test="${!testSourceDirFile.isAbsolute()}">
|
|
<j:set var="testSourceDir" value="${basedir}/${testSourceDir}"/>
|
|
</j:if>
|
|
|
|
<jxr:jxr
|
|
sourceDir="${testSourceDir}"
|
|
destDir="${maven.jxr.destdir.test}"
|
|
templateDir="${maven.jxr.templateDir}"
|
|
javadocDir="${null}"
|
|
windowTitle="${title}"
|
|
docTitle="${title}"
|
|
bottom="${copyright}">
|
|
</jxr:jxr>
|
|
|
|
</j:if>
|
|
|
|
</j:if>
|
|
|
|
</goal>
|
|
|
|
</project>
|