You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@directory.apache.org by Felix Knecht <fe...@apache.org> on 2010/05/29 16:16:16 UTC
Checkstyle ./ main/ main/resources/ main/resources/directory_checks.xml
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Following sites are generated using the checkstyle definition below.
Checkstyle reports are generated for each module on its own.
http://people.apache.org/~felixk/cs-shared-docs/
http://people.apache.org/~felixk/cs-apacheds-docs/
The configuration follows the suggestions made by Emmanuel
(http://www.archivum.info/dev@directory.apache.org/2010-05/00491/Checkstyle-report.html)
Felix
On 05/29/10 15:29, felixk@apache.org wrote:
> Author: felixk
> Date: Sat May 29 13:29:53 2010
> New Revision: 949388
>
> URL: http://svn.apache.org/viewvc?rev=949388&view=rev
> Log:
> Checkstyle configuration
>
> Added:
> directory/sandbox/felixk/build-tools/src/
> directory/sandbox/felixk/build-tools/src/main/
> directory/sandbox/felixk/build-tools/src/main/resources/
> directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml (with props)
>
> Added: directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml
> URL: http://svn.apache.org/viewvc/directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml?rev=949388&view=auto
> ==============================================================================
> --- directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml (added)
> +++ directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml Sat May 29 13:29:53 2010
> @@ -0,0 +1,199 @@
> +<?xml version="1.0" encoding="UTF-8"?>
> +
> +<!--
> + Licensed to the Apache Software Foundation (ASF) under one
> + or more contributor license agreements. See the NOTICE file
> + distributed with this work for additional information
> + regarding copyright ownership. The ASF licenses this file
> + to you under the Apache License, Version 2.0 (the
> + "License"); you may not use this file except in compliance
> + with the License. You may obtain a copy of the License at
> +
> + http://www.apache.org/licenses/LICENSE-2.0
> +
> + Unless required by applicable law or agreed to in writing,
> + software distributed under the License is distributed on an
> + "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
> + KIND, either express or implied. See the License for the
> + specific language governing permissions and limitations
> + under the License.
> +-->
> +
> +<!DOCTYPE module PUBLIC
> + "-//Puppy Crawl//DTD Check Configuration 1.2//EN"
> + "http://www.puppycrawl.com/dtds/configuration_1_2.dtd">
> +
> +<!--
> +
> + Checkstyle is very configurable. Be sure to read the documentation at
> + http://checkstyle.sf.net (or in your downloaded distribution).
> +
> + Most Checks are configurable, be sure to consult the documentation.
> +
> + To completely disable a check, just comment it out or delete it from the file.
> +
> + Finally, it is worth reading the documentation.
> +
> +-->
> +
> +<module name="Checker">
> + <!--
> + If you set the basedir property below, then all reported file
> + names will be relative to the specified directory. See
> + http://checkstyle.sourceforge.net/5.x/config.html#Checker
> +
> + <property name="basedir" value="${basedir}"/>
> + -->
> +
> + <!-- Checks that each Java package has a Javadoc file used for commenting. -->
> + <!-- See http://checkstyle.sf.net/config_javadoc.html#JavadocPackage -->
> + <!--
> + <module name="JavadocPackage">
> + <property name="allowLegacy" value="true"/>
> + </module>
> + -->
> +
> + <!-- Checks whether files end with a new line. -->
> + <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
> + <!-- module name="NewlineAtEndOfFile"/ -->
> +
> + <!-- Checks that property files contain the same keys. -->
> + <!-- See http://checkstyle.sf.net/config_misc.html#Translation -->
> + <module name="Translation"/>
> +
> + <module name="FileLength"/>
> +
> + <!-- Following interprets the header file as regular expressions. -->
> + <!-- <module name="RegexpHeader"/> -->
> +
> + <module name="FileTabCharacter">
> + <property name="eachLine" value="true"/>
> + </module>
> +
> + <!--
> + <module name="RegexpSingleline">
> + <!- \s matches whitespace character, $ matches end of line. ->
> + <property name="format" value="\s+$"/>
> + <property name="message" value="Line has trailing spaces."/>
> + </module>
> + -->
> +
> + <module name="TreeWalker">
> +
> + <property name="cacheFile" value="${checkstyle.cache.file}"/>
> +
> + <!-- Checks for Javadoc comments. -->
> + <!-- See http://checkstyle.sf.net/config_javadoc.html -->
> + <module name="JavadocMethod"/>
> + <module name="JavadocType"/>
> + <module name="JavadocVariable"/>
> + <module name="JavadocStyle">
> + <property name="checkFirstSentence" value="false"/>
> + </module>
> +
> +
> + <!-- Checks for Naming Conventions. -->
> + <!-- See http://checkstyle.sf.net/config_naming.html -->
> + <module name="ConstantName"/>
> + <module name="LocalFinalVariableName"/>
> + <module name="LocalVariableName"/>
> + <module name="MemberName"/>
> + <module name="MethodName"/>
> + <module name="PackageName"/>
> + <module name="ParameterName"/>
> + <module name="StaticVariableName"/>
> + <module name="TypeName"/>
> +
> +
> + <!-- Checks for Headers -->
> + <!-- See http://checkstyle.sf.net/config_header.html -->
> + <!-- <module name="Header"> -->
> + <!-- The follow property value demonstrates the ability -->
> + <!-- to have access to ANT properties. In this case it uses -->
> + <!-- the ${basedir} property to allow Checkstyle to be run -->
> + <!-- from any directory within a project. See property -->
> + <!-- expansion, -->
> + <!-- http://checkstyle.sf.net/config.html#properties -->
> + <!-- <property -->
> + <!-- name="headerFile" -->
> + <!-- value="${basedir}/java.header"/> -->
> + <!-- </module> -->
> +
> +
> + <!-- Checks for imports -->
> + <!-- See http://checkstyle.sf.net/config_import.html -->
> + <module name="AvoidStarImport"/>
> + <module name="IllegalImport"/> <!-- defaults to sun.* packages -->
> + <module name="RedundantImport"/>
> + <module name="UnusedImports"/>
> +
> +
> + <!-- Checks for Size Violations. -->
> + <!-- See http://checkstyle.sf.net/config_sizes.html -->
> + <!-- module name="LineLength"/ -->
> + <!--module name="MethodLength"/ -->
> + <module name="ParameterNumber"/>
> +
> +
> + <!-- Checks for whitespace -->
> + <!-- See http://checkstyle.sf.net/config_whitespace.html -->
> + <module name="EmptyForIteratorPad"/>
> + <!-- module name="MethodParamPad"/ -->
> + <!-- module name="NoWhitespaceAfter"/ -->
> + <!-- module name="NoWhitespaceBefore"/ -->
> + <module name="OperatorWrap"/>
> + <!-- module name="ParenPad"/ -->
> + <!-- module name="TypecastParenPad"/ -->
> + <!-- module name="WhitespaceAfter"/ -->
> + <!-- module name="WhitespaceAround"/ -->
> +
> +
> + <!-- Modifier Checks -->
> + <!-- See http://checkstyle.sf.net/config_modifiers.html -->
> + <module name="ModifierOrder"/>
> + <module name="RedundantModifier"/>
> +
> +
> + <!-- Checks for blocks. You know, those {}'s -->
> + <!-- See http://checkstyle.sf.net/config_blocks.html -->
> + <module name="AvoidNestedBlocks"/>
> + <module name="EmptyBlock"/>
> + <!-- module name="LeftCurly"/ -->
> + <module name="NeedBraces"/>
> + <!-- module name="RightCurly"/ -->
> +
> +
> + <!-- Checks for common coding problems -->
> + <!-- See http://checkstyle.sf.net/config_coding.html -->
> + <module name="AvoidInlineConditionals"/>
> + <module name="DoubleCheckedLocking"/> <!-- MY FAVOURITE -->
> + <module name="EmptyStatement"/>
> + <module name="EqualsHashCode"/>
> + <module name="HiddenField"/>
> + <module name="IllegalInstantiation"/>
> + <module name="InnerAssignment"/>
> + <!-- module name="MagicNumber"/ -->
> + <module name="MissingSwitchDefault"/>
> + <module name="RedundantThrows"/>
> + <module name="SimplifyBooleanExpression"/>
> + <module name="SimplifyBooleanReturn"/>
> +
> + <!-- Checks for class design -->
> + <!-- See http://checkstyle.sf.net/config_design.html -->
> + <!-- module name="DesignForExtension"/ -->
> + <module name="FinalClass"/>
> + <module name="HideUtilityClassConstructor"/>
> + <module name="InterfaceIsType"/>
> + <module name="VisibilityModifier"/>
> +
> +
> + <!-- Miscellaneous other checks. -->
> + <!-- See http://checkstyle.sf.net/config_misc.html -->
> + <module name="ArrayTypeStyle"/>
> + <!-- module name="FinalParameters"/ -->
> + <module name="TodoComment"/>
> + <module name="UpperEll"/>
> +
> + </module>
> +
> +</module>
>
> Propchange: directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml
> ------------------------------------------------------------------------------
> svn:eol-style = native
>
> Propchange: directory/sandbox/felixk/build-tools/src/main/resources/directory_checks.xml
> ------------------------------------------------------------------------------
> svn:keywords = Author Date Id Revision
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.15 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkwBIbAACgkQ2lZVCB08qHFOiwCgnKFNYRxXDl+SNFVQyjts+0uP
tEIAniWX7WBZoUfnQQ3fK/UVc3AZOtoN
=BhLJ
-----END PGP SIGNATURE-----
Re: Checkstyle ./ main/ main/resources/ main/resources/directory_checks.xml
Posted by Felix Knecht <fe...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
It's only how it could be. I haven't added definitely as we still need
to see how to do it - if adding a new project for build tools like this
and the docbook things, if we can/will do this in the same project or in
different modules and how to name it.
WDOT?
On 05/29/10 16:53, Emmanuel Lecharny wrote:
> On 5/29/10 4:16 PM, Felix Knecht wrote:
>> -----BEGIN PGP SIGNED MESSAGE-----
>> Hash: SHA1
>>
>> Following sites are generated using the checkstyle definition below.
>> Checkstyle reports are generated for each module on its own.
>> http://people.apache.org/~felixk/cs-shared-docs/
>> http://people.apache.org/~felixk/cs-apacheds-docs/
>>
>> The configuration follows the suggestions made by Emmanuel
>> (http://www.archivum.info/dev@directory.apache.org/2010-05/00491/Checkstyle-report.html)
>>
>>
>
> Many thanks, felix !
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.15 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
iEYEARECAAYFAkwBO6gACgkQ2lZVCB08qHEH9gCgxFSvJn6mVKCMItxsF4qg2Jvo
kl0AoJiHw+3f0aQPcS2M3sMTvdaxBW4H
=lAQi
-----END PGP SIGNATURE-----
Re: Checkstyle ./ main/ main/resources/ main/resources/directory_checks.xml
Posted by Emmanuel Lecharny <el...@gmail.com>.
On 5/29/10 4:16 PM, Felix Knecht wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Following sites are generated using the checkstyle definition below.
> Checkstyle reports are generated for each module on its own.
> http://people.apache.org/~felixk/cs-shared-docs/
> http://people.apache.org/~felixk/cs-apacheds-docs/
>
> The configuration follows the suggestions made by Emmanuel
> (http://www.archivum.info/dev@directory.apache.org/2010-05/00491/Checkstyle-report.html)
>
Many thanks, felix !
--
Regards,
Cordialement,
Emmanuel Lécharny
www.nextury.com