Skip to content

Commit

Permalink
fixed path issues, make checkstyle maven integration and plugin runnable
Browse files Browse the repository at this point in the history
with the same configuration
  • Loading branch information
alexbalakirev committed Jun 28, 2024
1 parent b23fdac commit 748a7c2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
5 changes: 2 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -190,9 +190,8 @@
<version>3.4.0</version>
<configuration>
<failsOnError>true</failsOnError>
<configLocation>${basedir}/src/main/resources/checkstyle.xml</configLocation>
<suppressionsLocation>${basedir}/src/main/resources/suppressions.xml</suppressionsLocation>
<propertyExpansion>config_loc=${basedir}</propertyExpansion>
<configLocation>${basedir}${file.separator}src${file.separator}main${file.separator}resources${file.separator}checkstyle.xml</configLocation>
<propertyExpansion>config_loc=${basedir}${file.separator}src${file.separator}main${file.separator}resources</propertyExpansion>
</configuration>
<dependencies>
<dependency>
Expand Down
16 changes: 5 additions & 11 deletions src/main/resources/checkstyle.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
This configuration file was written by the eclipse-cs plugin configuration editor
-->
<!--
Checkstyle-Configuration: Copy of Google Checks
Description:
Checkstyle configuration that checks the Google coding conventions from Google Java Style that can be found at https://google.github.io/styleguide/javaguide.html.
Checkstyle-Configuration: Google Checks PR
Description: none
-->
<module name="Checker">
<property name="severity" value="warning"/>
Expand Down Expand Up @@ -169,7 +168,6 @@ Checkstyle configuration that checks the Google coding conventions from Google J
<property name="caseIndent" value="2"/>
</module>
<module name="AbbreviationAsWordInName">
<property name="allowedAbbreviationLength" value="3"/>
<property name="ignoreFinal" value="false"/>
<property name="tokens" value="CLASS_DEF, INTERFACE_DEF, ENUM_DEF, ANNOTATION_DEF, ANNOTATION_FIELD_DEF, PARAMETER_DEF, VARIABLE_DEF, METHOD_DEF, PATTERN_VARIABLE_DEF, RECORD_DEF, RECORD_COMPONENT_DEF"/>
</module>
Expand Down Expand Up @@ -223,9 +221,10 @@ Checkstyle configuration that checks the Google coding conventions from Google J
<property name="tokens" value="METHOD_DEF, CTOR_DEF, ANNOTATION_FIELD_DEF, COMPACT_CTOR_DEF"/>
</module>
<module name="MissingJavadocMethod">
<property name="severity" value="warning"/>
<property name="allowedAnnotations" value="Override, Test"/>
<property name="minLineCount" value="2"/>
<property name="tokens" value="METHOD_DEF, CTOR_DEF, ANNOTATION_FIELD_DEF, COMPACT_CTOR_DEF"/>
<property name="tokens" value="METHOD_DEF, CTOR_DEF, ANNOTATION_FIELD_DEF, COMPACT_CTOR_DEF"/>
</module>
<module name="MissingJavadocType">
<property name="excludeScope" value="nothing"/>
Expand All @@ -243,10 +242,6 @@ Checkstyle configuration that checks the Google coding conventions from Google J
<module name="CommentsIndentation">
<property name="tokens" value="SINGLE_LINE_COMMENT, BLOCK_COMMENT_BEGIN"/>
</module>
<module name="SuppressionXpathFilter">
<property name="file" value="suppressions.xml"/>
<property name="optional" value="true"/>
</module>
<module name="SuppressWarningsHolder"/>
<module name="SuppressionCommentFilter">
<property name="checkFormat" value="$1"/>
Expand All @@ -268,8 +263,7 @@ Checkstyle configuration that checks the Google coding conventions from Google J
<property name="fileNamePattern" value="module\-info\.java$"/>
</module>
<module name="SuppressionFilter">
<property name="file" value="${config_loc}/src/main/resources/suppressions.xml"/>
<property name="optional" value="false"/>
<property name="file" value="${config_loc}/suppressions.xml"/>
</module>
<module name="LineLength">
<property name="fileExtensions" value="java"/>
Expand Down

0 comments on commit 748a7c2

Please sign in to comment.