Author: [email protected]
Date: Thu Apr 21 16:01:58 2011
New Revision: 1034

Log:
[AMDATUCASSANDRA-7] Moved checkstyle config to cassandra project

Added:
   trunk/amdatu-cassandra/etc/
   trunk/amdatu-cassandra/etc/checkstyle/
   trunk/amdatu-cassandra/etc/checkstyle/amdatu_checks.xml
Removed:
   trunk/etc/checkstyle/
Modified:
   trunk/amdatu-cassandra/pom.xml
   trunk/amdatu-parent/pom.xml

Added: trunk/amdatu-cassandra/etc/checkstyle/amdatu_checks.xml
==============================================================================
--- (empty file)
+++ trunk/amdatu-cassandra/etc/checkstyle/amdatu_checks.xml     Thu Apr 21 
16:01:58 2011
@@ -0,0 +1,225 @@
+<?xml version="1.0"?>
+<!DOCTYPE module PUBLIC
+          "-//Puppy Crawl//DTD Check Configuration 1.3//EN"
+          "http://www.puppycrawl.com/dtds/configuration_1_3.dtd";>
+
+<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 property files contain the same keys.         -->
+    <!-- See http://checkstyle.sf.net/config_misc.html#Translation -->
+    <module name="Translation"/>
+
+    <!-- Checks for Size Violations.                    -->
+    <!-- See http://checkstyle.sf.net/config_sizes.html -->
+    <module name="FileLength"/>
+
+    <!-- Checks for whitespace                               -->
+    <!-- See http://checkstyle.sf.net/config_whitespace.html -->
+    <module name="FileTabCharacter"/>
+
+    <!-- Miscellaneous other checks.                   -->
+    <!-- See http://checkstyle.sf.net/config_misc.html -->
+    <module name="RegexpSingleline">
+       <property name="format" value="[^\*]\s+$"/>
+       <property name="minimum" value="0"/>
+       <property name="maximum" value="0"/>
+       <property name="message" value="Line has trailing spaces."/>
+    </module>
+
+    <module name="TreeWalker">
+
+        <!-- Checks for Javadoc comments.                     -->
+        <!-- See http://checkstyle.sf.net/config_javadoc.html -->
+        <module name="JavadocMethod">
+          <property name="scope" value="public"/>
+          <property name="tokens" value="INTERFACE_DEF"/>
+        </module>
+        <module name="JavadocType">
+          <property name="scope" value="public"/>
+          <property name="tokens" value="INTERFACE_DEF"/>
+        </module>
+        <module name="JavadocVariable">
+          <property name="scope" value="public"/>
+        </module>
+        <module name="JavadocStyle"/>
+
+
+        <!-- Checks for Naming Conventions.                  -->
+        <!-- See http://checkstyle.sf.net/config_naming.html -->
+        <module name="ConstantName"/>
+        <module name="LocalFinalVariableName"/>
+        <module name="LocalVariableName"/>
+        <module name="MemberName">
+          <property name="format" value="^m_[a-z][a-zA-Z0-9]*$"/>
+        </module>
+        <module name="MethodName"/>
+        <module name="PackageName"/>
+        <module name="ParameterName"/>
+        <module name="StaticVariableName">
+          <property name="format" value="^[A-Z][A-Z0-9_]*$"/>
+        </module>
+        <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> -->
+
+        <!-- Following interprets the header file as regular expressions. -->
+        <!-- <module name="RegexpHeader"/>                                -->
+
+
+        <!-- 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">
+          <property name="max" value="120"/>
+        </module>
+        <module name="MethodLength"/>
+        <module name="ParameterNumber"/>
+
+
+        <!-- Checks for whitespace                               -->
+        <!-- See http://checkstyle.sf.net/config_whitespace.html -->
+        <module name="EmptyForIteratorPad"/>
+        <module name="GenericWhitespace"/>
+        <module name="MethodParamPad"/>
+        <module name="NoWhitespaceAfter"/>
+        <module name="NoWhitespaceBefore"/>
+        <module name="OperatorWrap"/>
+        <module name="ParenPad"/>
+        <module name="TypecastParenPad"/>
+        <module name="WhitespaceAfter"/>
+        <module name="WhitespaceAround">
+          <property name="tokens" value="ASSIGN"/>
+          <property name="tokens" value="BAND"/>
+          <property name="tokens" value="BAND_ASSIGN"/>
+          <property name="tokens" value="BOR"/>
+          <property name="tokens" value="BOR_ASSIGN"/>
+          <property name="tokens" value="BSR"/>
+          <property name="tokens" value="BSR_ASSIGN"/>
+          <property name="tokens" value="BXOR"/>
+          <property name="tokens" value="BXOR_ASSIGN"/>
+          <property name="tokens" value="COLON"/>
+          <property name="tokens" value="DIV"/>
+          <property name="tokens" value="DIV_ASSIGN"/>
+          <property name="tokens" value="EQUAL"/>
+          <property name="tokens" value="GE"/>
+          <property name="tokens" value="GT"/>
+          <property name="tokens" value="LAND"/>
+          <property name="tokens" value="LE"/>
+          <property name="tokens" value="LITERAL_ASSERT"/>
+          <property name="tokens" value="LITERAL_CATCH"/>
+          <property name="tokens" value="LITERAL_DO"/>
+          <property name="tokens" value="LITERAL_ELSE"/>
+          <property name="tokens" value="LITERAL_FINALLY"/>
+          <property name="tokens" value="LITERAL_FOR"/>
+          <property name="tokens" value="LITERAL_IF"/>
+          <property name="tokens" value="LITERAL_RETURN"/>
+          <property name="tokens" value="LITERAL_SYNCHRONIZED"/>
+          <property name="tokens" value="LITERAL_TRY"/>
+          <property name="tokens" value="LITERAL_WHILE"/>
+          <property name="tokens" value="LOR"/>
+          <property name="tokens" value="LT"/>
+          <property name="tokens" value="MINUS"/>
+          <property name="tokens" value="MINUS_ASSIGN"/>
+          <property name="tokens" value="MOD"/>
+          <property name="tokens" value="MOD_ASSIGN"/>
+          <property name="tokens" value="NOT_EQUAL"/>
+          <property name="tokens" value="PLUS"/>
+          <property name="tokens" value="PLUS_ASSIGN"/>
+          <property name="tokens" value="QUESTION"/>
+          <property name="tokens" value="SL"/>
+          <property name="tokens" value="SLIST"/>
+          <property name="tokens" value="SL_ASSIGN"/>
+          <property name="tokens" value="SR"/>
+          <property name="tokens" value="SR_ASSIGN"/>
+          <property name="tokens" value="STAR"/>
+          <property name="tokens" value="STAR_ASSIGN"/>
+          <property name="tokens" value="TYPE_EXTENSION_AND"/>
+          <property name="allowEmptyConstructors" value="true"/>
+          <property name="allowEmptyMethods" value="true"/>
+        </module>
+
+
+        <!-- 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">
+          <property name="tokens" value="LITERAL_DO"/>
+          <property name="tokens" value="LITERAL_ELSE"/>
+          <property name="tokens" value="LITERAL_FINALLY"/>
+          <property name="tokens" value="LITERAL_IF"/>
+          <property name="tokens" value="LITERAL_FOR"/>
+          <property name="tokens" value="LITERAL_TRY"/>
+          <property name="tokens" value="LITERAL_WHILE"/>
+          <property name="tokens" value="INSTANCE_INIT"/>
+          <property name="tokens" value="STATIC_INIT"/>
+        </module>
+        <module name="LeftCurly"/>
+        <module name="NeedBraces"/>
+        <module name="RightCurly">
+          <property name="option" value="alone"/>
+        </module>
+
+        <!-- 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="MissingSwitchDefault"/>
+        <module name="RedundantThrows"/>
+        <module name="SimplifyBooleanExpression"/>
+        <module name="SimplifyBooleanReturn"/>
+
+        <!-- Checks for class design                         -->
+        <!-- See http://checkstyle.sf.net/config_design.html -->
+        <module name="FinalClass"/>
+        <module name="HideUtilityClassConstructor"/>
+        <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>

Modified: trunk/amdatu-cassandra/pom.xml
==============================================================================
--- trunk/amdatu-cassandra/pom.xml      (original)
+++ trunk/amdatu-cassandra/pom.xml      Thu Apr 21 16:01:58 2011
@@ -250,6 +250,20 @@
   <reporting>
     <plugins>
       <plugin>
+        <artifactId>maven-checkstyle-plugin</artifactId>
+        <version>2.6</version>
+        <configuration>
+          <!-- Aggregation is not yet supported in 2.6. A highly popular JIRA 
issue has
+               been created to resolve this issue: 
http://jira.codehaus.org/browse/MCHECKSTYLE-62
+               <aggregate>true</aggregate>
+          -->
+
+          <linkXref>true</linkXref>
+          <configLocation>etc/checkstyle/amdatu_checks.xml</configLocation>
+          <enableRulesSummary>false</enableRulesSummary>
+        </configuration>
+      </plugin>
+      <plugin>
         <artifactId>maven-javadoc-plugin</artifactId>
         <version>2.7</version>
         <configuration>

Modified: trunk/amdatu-parent/pom.xml
==============================================================================
--- trunk/amdatu-parent/pom.xml (original)
+++ trunk/amdatu-parent/pom.xml Thu Apr 21 16:01:58 2011
@@ -311,22 +311,6 @@
   <reporting>
     <outputDirectory>target/site</outputDirectory>
     <plugins>
-
-      <plugin>
-        <artifactId>maven-checkstyle-plugin</artifactId>
-        <version>2.6</version>
-        <configuration>
-          <!-- Aggregation is not yet supported in 2.6. A highly popular JIRA 
issue has
-               been created to resolve this issue: 
http://jira.codehaus.org/browse/MCHECKSTYLE-62
-               <aggregate>true</aggregate>
-          -->
-
-          <linkXref>true</linkXref>
-          <configLocation>../etc/checkstyle/amdatu_checks.xml</configLocation>
-          <enableRulesSummary>false</enableRulesSummary>
-        </configuration>
-      </plugin>
-
       <plugin>
         <artifactId>maven-javadoc-plugin</artifactId>
         <version>2.7</version>
_______________________________________________
Amdatu-commits mailing list
[email protected]
http://lists.amdatu.org/mailman/listinfo/amdatu-commits

Reply via email to