checkstyle accpting other resources than just fileset

"Dever, Jeffrey" <[email protected]> Fri, 27 Mar 2009 11:55:59 -0400
Newsgroups gmane.comp.java.audit.checkstyle.user
Message-ID <[email protected]>
We just started using checkstyle in our Java 6 codebase with Ant.  It
seems that Ant is going through a mild revolution in terms of Resource
Collections in its data types, which is a good thing.

 

I bring this up because the checkstyle ant task only takes a single file
or a fileset as input.  The problem is that I have my source files in
several directories that are defined as a path, a sourcepath that is
used with many tasks including javac, javadoc, etc.  Unfortunately Ant
doesn't make it easy to convert from a path to a fileset, and the
ant-contrib task of pathtofileset doesn't actually make a fileset of the
files in the path, just of the paths themselves.  If I do this and pass
the new fileset to the checkstyle ant task it doesn't find any java
files.

 

When I discussed this on the ant mailing list, it was suggested that
checkstyle support paths as well as filesets for specifying source
files.
http://mail-archives.apache.org/mod_mbox/ant-user/200903.mbox/%3c49CBFEA
[email protected]%3e

 

I had a quick look at doing this in the checkstyle task. With the
assumption that a provided path specifies a number of root directories
that are expanded into source trees, doesn't seem too difficult.  To
handle all resource types appears to be quite a bit more effort at first
glance but still not complex. 

 

I would consider this behaviour to be a valuable addition and am willing
to take this on for 5.0 if someone else isn't looking at it already.

------------------------------------------------------------------------------

_______________________________________________
Checkstyle-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/checkstyle-user