You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by jactor <to...@hotmail.com> on 2008/05/06 16:47:42 UTC

Checkstyle configLocation error

Hi!

I have configured maven to run a checkstyle when mvn site is used. Here is
the configuration:

     
  <modules>
    <module>children.project.jar</module>
    ...
  </modules>
  ...
  <plugin>
    <groupId>org.apache.maven.plugins</groupId>
      <artifactId>maven-checkstyle-plugin</artifactId>
      <configuration>
        <configLocation>checkstyle.xml</configLocation>
        <enableRulesSummary>true</enableRulesSummary>
      </configuration>
    </plugin>

However, it crashes when I use the config location. I have a main pom
projects which have the checkstyle.xml but it can not be found in the child
projects. Projects like this:

project.main.pom
> checkstyle.xml is located in this folder...
> children.project.jar
  > produses this error when mvn site is runned:

Cobertura: Loaded information on 30 classes.
Cobertura: Saved information on 30 classes.
[INFO] [site:site]
[INFO] Skipped "Maven Surefire Report" report, file "surefire-report.html"
already exists for the English version.
[INFO] Generating "Checkstyle" report.
[INFO]
------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO]
------------------------------------------------------------------------
[INFO] Error during page generation

Embedded error: Error rendering Maven report: Unable to find configuration
file location.
Unable to find location 'checkstyle.xml' as URL, File or Resource.
-- 
View this message in context: http://www.nabble.com/Checkstyle-configLocation-error-tp17084338p17084338.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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


RE: Checkstyle configLocation error

Posted by "Brian E. Fox" <br...@reply.infinity.nu>.
You can see a way to bundle and share the config here:
http://blogs.sonatype.com/brian/2008/04/17/1208485500000.html  (at the
end, I specifically talk about the checkstyle use)

-----Original Message-----
From: jactor [mailto:toregiljacobsen@hotmail.com] 
Sent: Tuesday, May 06, 2008 8:00 AM
To: users@maven.apache.org
Subject: Re: Checkstyle configLocation error


I went playing with my checkstyle configuration and modified the
following:

        <configLocation>../checkstyle.xml</configLocation>

Original:

jactor wrote:
> 
>         <configLocation>checkstyle.xml</configLocation>
> 

I know have a system which runs with the correct checkstyle.xml :-D.

If I want to reuse this checkstyle xml in other projects, can I override
the
current setting? I would like other main projects to have this main pom
as
parent to enable common configuration.
-- 
View this message in context:
http://www.nabble.com/Checkstyle-configLocation-error-tp17084338p1708471
7.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
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


Re: Checkstyle configLocation error

Posted by jactor <to...@hotmail.com>.
I went playing with my checkstyle configuration and modified the following:

        <configLocation>../checkstyle.xml</configLocation>

Original:

jactor wrote:
> 
>         <configLocation>checkstyle.xml</configLocation>
> 

I know have a system which runs with the correct checkstyle.xml :-D.

If I want to reuse this checkstyle xml in other projects, can I override the
current setting? I would like other main projects to have this main pom as
parent to enable common configuration.
-- 
View this message in context: http://www.nabble.com/Checkstyle-configLocation-error-tp17084338p17084717.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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