Maven 1.x Checkstyle Plugin

The checkstyle report should use the maven.xdoc.locale.default

Details

  • Type: Wish Wish
  • Status: Reopened Reopened
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 2.5
  • Fix Version/s: 3.0
  • Component/s: None
  • Labels:
    None
  • Environment:
    maven 1.1 beta 2
  • Number of attachments :
    0

Description

The checkstyle locale is actually defined from the JVM and not from the property : maven.xdoc.locale.default
If I have a project with maven.xdoc.locale.default=En but I build it on a french system, the checkstyle report will be generated in French.

Activity

Hide
Arnaud Heritier added a comment -

We should use the properties localeCountry and localeLanguage for the checker :
http://checkstyle.sourceforge.net/config.html#Checker
These properties can be constructed from ${maven.xdoc.locale.default }

Show
Arnaud Heritier added a comment - We should use the properties localeCountry and localeLanguage for the checker : http://checkstyle.sourceforge.net/config.html#Checker These properties can be constructed from ${maven.xdoc.locale.default }
Hide
Arnaud Heritier added a comment -

Fixe. Works only for the country code.

Show
Arnaud Heritier added a comment - Fixe. Works only for the country code.
Hide
Eric Ballet Baz added a comment -

This is not fixed : the property "maven.xdoc.locale.default" is used as the country code, but the value of the "maven.xdoc.locale.default" property is not the country code ! It is the language code ...
Checkstyle doesn't recognized the country code as a locale.

You should define the "Checker" Checkstyle module by using the property "localeLanguage", not "localeCountry"

so in the files xxx_checks.xml, you should replace :

<property name="localeCountry" value="${checkstyle.localeCountry}"/>
with
<property name="localeLanguage" value="${checkstyle.localeCountry}"/>

or better with
<property name="localeLanguage" value="${checkstyle.localeLanguage}"/>
and update the plugin.jelly file to define checkstyle.localeLanguage instead of checkstyle.localeCountry

Eric Ballet Baz

Show
Eric Ballet Baz added a comment - This is not fixed : the property "maven.xdoc.locale.default" is used as the country code, but the value of the "maven.xdoc.locale.default" property is not the country code ! It is the language code ... Checkstyle doesn't recognized the country code as a locale. You should define the "Checker" Checkstyle module by using the property "localeLanguage", not "localeCountry" so in the files xxx_checks.xml, you should replace : <property name="localeCountry" value="${checkstyle.localeCountry}"/> with <property name="localeLanguage" value="${checkstyle.localeCountry}"/> or better with <property name="localeLanguage" value="${checkstyle.localeLanguage}"/> and update the plugin.jelly file to define checkstyle.localeLanguage instead of checkstyle.localeCountry Eric Ballet Baz
Hide
Arnaud Heritier added a comment -

Reopen to review Eric's comment

Show
Arnaud Heritier added a comment - Reopen to review Eric's comment

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated: