I added:
<module name="GenericIllegalRegexp">
<property name="format" value="\s+$"/>
<property name="message" value="Line has trailing spaces."/>
</module>
<module name="GenericIllegalRegexp">
<!-- . matches any character, so we need to
escape it and use \. to match dots. -->
<property name="format" value="System\.out\.println"/>
</module>
<module name="GenericIllegalRegexp">
<!-- . matches any character, so we need to
escape it and use \. to match dots. -->
<property name="format" value="e\.printStackTrace"/>
</module>
and in each class, the errors show up, but in the accumulated errors list,
the numbers are all zero even though there are around 5 errors in the src
tree. Any idea why?
On 8/10/07, Dennis Lundberg <[EMAIL PROTECTED]> wrote:
>
> You can use the Regexp module [1] like this:
>
> <module name="Regexp">
> <!-- . matches any character, so we need to
> escape it and use \. to match dots. -->
> <property name="format" value="System\.out\.println"/>
> <property name="illegalPattern" value="true"/>
> </module>
>
> or the GenericIllegalRegexp [2] like this:
>
> <module name="GenericIllegalRegexp">
> <!-- . matches any character, so we need to
> escape it and use \. to match dots. -->
> <property name="format" value="System\.out\.println"/>
> </module>
>
>
> Read more:
> [1] http://checkstyle.sourceforge.net/config_misc.html#Regexp
> [2]
> http://checkstyle.sourceforge.net/config_misc.html#GenericIllegalRegexp
>
> Mick Knutson wrote:
> > I have checkstyle. How do I do it in Checkstyle?
> >
> >
> >
> >
> > On 8/10/07, Dennis Lundberg <[EMAIL PROTECTED]> wrote:
> >> Mick Knutson wrote:
> >>> I want to get a tag list of all the System.out.println(...) statements
> >> there
> >>> are and I want it to show up as:
> >>>
> >>>
> >>> System.out.println("some print statement);
> >>>
> >>> NOT:
> >>>
> >>> ("some print statement);
> >> What is the purpose of that? Do you want to avoid having System.out
> >> calls in your code? In that case you should be using Checkstyle
> instead.
> >>
> >> --
> >> Dennis Lundberg
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> >
>
>
> --
> Dennis Lundberg
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
--
Thanks,
Mick Knutson
http://www.baselogic.com
http://www.blincmagazine.com
http://www.djmick.com
http://www.myspace.com/mickknutson
http://www.myspace.com/djmick_dot_com
http://www.myspace.com/sexybeotches
http://www.thumpradio.com
---