I register reports only if source, test,... exists. git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@113563 13f79535-47bb-0310-9956-ffa450edef68
82 lines
2.5 KiB
XML
82 lines
2.5 KiB
XML
<?xml version="1.0"?>
|
|
|
|
<project
|
|
xmlns:j="jelly:core"
|
|
xmlns:ant="jelly:ant"
|
|
xmlns:define="jelly:define"
|
|
xmlns:changelog="changelog"
|
|
xmlns:doc="doc">
|
|
|
|
<goal name="maven-changelog-plugin:register">
|
|
<j:if test="${context.getVariable('maven.mode.online') == null}">
|
|
<j:set var="maven.mode.online" value="true" />
|
|
</j:if>
|
|
<j:if test="${maven.mode.online}">
|
|
<doc:registerReport
|
|
name="Change Log"
|
|
pluginName="maven-changelog-plugin"
|
|
link="changelog-report"
|
|
description="Report on the source control changelog."/>
|
|
</j:if>
|
|
</goal>
|
|
|
|
<goal name="maven-changelog-plugin:deregister">
|
|
<doc:deregisterReport name="Change Log"/>
|
|
</goal>
|
|
|
|
<define:taglib uri="changelog">
|
|
<define:jellybean
|
|
name="changelog"
|
|
className="org.apache.maven.changelog.ChangeLog"
|
|
method="doExecute"
|
|
/>
|
|
</define:taglib>
|
|
|
|
<!-- ================================================================== -->
|
|
<!-- C H A N G E L O G R E P O R T -->
|
|
<!-- ================================================================== -->
|
|
|
|
<goal
|
|
name="maven-changelog-plugin:report"
|
|
description="Generate a changelog report">
|
|
|
|
<j:if test="${context.getVariable('maven.mode.online') == null}">
|
|
<j:set var="maven.mode.online" value="true"/>
|
|
</j:if>
|
|
<j:choose>
|
|
<j:when test="${maven.mode.online}">
|
|
<j:set var="_connection">${pom.repository.connection}</j:set>
|
|
<j:if test="${!empty(_connection)}">
|
|
<ant:echo>Generating the changelog report</ant:echo>
|
|
|
|
<changelog:changelog
|
|
basedir="${basedir}"
|
|
developers="${pom.developers}"
|
|
factory="${maven.changelog.factory}"
|
|
output="${maven.build.dir}/changelog.xml"
|
|
outputEncoding="${maven.docs.outputencoding}"
|
|
range="${maven.changelog.range}"
|
|
repositoryConnection="${pom.repository.connection}"
|
|
dateFormat="${maven.changelog.dateformat}"
|
|
/>
|
|
|
|
<doc:jsl
|
|
input="${maven.build.dir}/changelog.xml"
|
|
output="changelog-report.xml"
|
|
stylesheet="${plugin.resources}/changelog.jsl"
|
|
encoding="${maven.docs.outputencoding}"
|
|
omitXmlDeclaration="false"
|
|
outputMode="xml"
|
|
prettyPrint="true"
|
|
/>
|
|
|
|
</j:if>
|
|
</j:when>
|
|
<j:otherwise>
|
|
<ant:echo>The Changelog is available in the online mode only.</ant:echo>
|
|
</j:otherwise>
|
|
</j:choose>
|
|
|
|
</goal>
|
|
</project>
|