maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@multitask.com.au
Subject Re: Ant classpath and Maven repository
Date Tue, 02 Dec 2003 23:11:07 GMT
Why not just tailor the pmd plugin using properties?

Here's a snippet from one of our project.properties files:


maven.pmd.rulesetfiles=${basedir}/../GeneralCommon/pmd.xml,\
  rulesets/basic.xml,\
  rulesets/unusedcode.xml,\
  rulesets/imports.xml,\
  rulesets/codesize.xml,\
  rulesets/coupling.xml,\
  rulesets/design.xml,\
  rulesets/strings.xml


Note the first entry is a file for our customising of pmd and has this in 
it:


<?xml version="1.0"?>

<ruleset name="Hidden">
  <description>
The Favorites ruleset contains links to rules that I like to use.  Usually 
I
combine this ruleset with the unusedcode.xml, basic.xml, and import.xml 
rulesets for my projects.
This ruleset also serves as an example of do a custom ruleset.
  </description>

  <rule ref="rulesets/controversial.xml/UnnecessaryConstructorRule"/>
  <rule ref="rulesets/controversial.xml/NullAssignment"/>
  <rule ref="rulesets/controversial.xml/AssignmentInOperandRule"/>

  <rule ref="rulesets/naming.xml">
    <exclude name="ShortVariable"/>
    <exclude name="LongVariable"/>
  </rule>

</ruleset>


Does this help at all?
--
dIon Gillard, Multitask Consulting
Blog:      http://blogs.codehaus.org/people/dion/



Mikael Lundgren <mikael.lundgren@leanon.se> wrote on 03/12/2003 09:18:03 
AM:

> Well, that's what I ended up doing, only I created my own plugin from 
> the PMD plugin, that way if there are updates to the PMD plugin won't 
> affect my changes.
> 
> Anyway it was a good experience learning how easy it really is to create 

> a plugin for Maven.
> 
> I guess that what I need is to truly understand how Jelly works.
> 
> /Mikael
> 
> dion@multitask.com.au wrote:
> 
> > Can't you just use and tailor the PMD plugin?
> > 
> > That's what I do.
> > --
> > dIon Gillard, Multitask Consulting
> > Blog:      http://blogs.codehaus.org/people/dion/
> > 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message