maven-plugins/jdepend/plugin.jelly

55 lines
1.5 KiB
XML

<?xml version="1.0"?>
<project xmlns:j="jelly:core" xmlns:doc="doc">
<goal name="maven-jdepend-plugin:register">
<doc:registerReport
name="Metrics"
pluginName="maven-jdepend-plugin"
link="jdepend-report"
description="Report on source code metrics."/>
</goal>
<goal name="maven-jdepend-plugin:deregister">
<doc:deregisterReport name="Metrics"/>
</goal>
<!-- ================================================================== -->
<!-- J D E P E N D X M L T A R G E T -->
<!-- ================================================================== -->
<goal
name="maven-jdepend-plugin:report"
description="Generate a dependency report with JDepend">
<j:if test="${sourcesPresent == 'true'}">
<attainGoal name="java:compile"/>
<java
classname="jdepend.xmlui.JDepend"
fork="true"
failonerror="true">
<arg line="-file '${maven.build.dir}/jdepend-raw-report.xml' '${maven.build.dest}'"/>
<classpath>
<path refid="maven-classpath"/>
<path refid="maven.dependency.classpath"/>
<pathelement path="${plugin.getDependencyPath('jdepend')}"/>
</classpath>
</java>
<doc:jsl
input="${maven.build.dir}/jdepend-raw-report.xml"
output="jdepend-report.xml"
stylesheet="${plugin.resources}/jdepend.jsl"
omitXmlDeclaration="true"
outputMode="xml"
prettyPrint="true"
/>
</j:if>
</goal>
</project>