[ 
https://jira.codehaus.org/browse/MCHECKSTYLE-187?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=358105#comment-358105
 ] 

Peter Palaga commented on MCHECKSTYLE-187:
------------------------------------------

I was about to vote this up but then I found a config that works for me and 
probably will work also for the reporter.

My use case is that I want to check tabs and trailing spaces in {{pom.xml}} 
files. Simply setting  {{<sourceDirectory>$\{basedir\}</sourceDirectory>}} 
includes {{pom.xml}} but also pulls all submodule directories in, which I do 
not want. To get rid of the submodules, one needs to find adequate patterns for 
{{<include>}}. In my case:
{code:language=html/xml}
<sourceDirectory>${basedir}</sourceDirectory>
<includes>*.xml,src/**/*.xml,src/**/*.java,</includes>
{code}

The reporter's problem should be solved by something like
{code:language=html/xml}
<sourceDirectory>${basedir}/src</sourceDirectory>
<includes>*.*</includes>
{code}


> Enable checkstyle for all files in project
> ------------------------------------------
>
>                 Key: MCHECKSTYLE-187
>                 URL: https://jira.codehaus.org/browse/MCHECKSTYLE-187
>             Project: Maven Checkstyle Plugin
>          Issue Type: Improvement
>    Affects Versions: 2.9.1
>         Environment: Apache Maven 3.0.4 (r1232337; 2012-01-17 09:44:56+0100)
> Java version: 1.6.0_33, vendor: Sun Microsystems Inc.
> OS name: "linux", version: "3.2.0-36-generic", arch: "amd64", family: "unix"
>            Reporter: Lukasz Strzelecki
>
> When I have module configured as war (packaging war). Checkstyle plugin 
> should check for all file in project i.e.
> * /src/main/java
> * /src/main/resources
> * /src/main/webapp
> when includeTestSourceDirectory is enabled, chekckstyle plugin should add 
> more paths like:
> * /src/test/java
> * /src/test/resources
> * /src/test/webapp



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)

Reply via email to