Skip to content

Commit 39a1657

Browse files
committed
Upgrade Checkstyle to 8.29
Adapt checkstyle configuration with new changes: * Move cacheFile to Checker module * Move LineLength to Checker module * Use SuppressWithPlainTextCommentFilter
1 parent 3a4a9f8 commit 39a1657

3 files changed

Lines changed: 12 additions & 7 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,3 +26,4 @@ test-output
2626

2727
dependency-reduced-pom.xml
2828
.flattened-pom.xml
29+
checkstyle.cache

etc/checkstyle.xml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
<property name="basedir" value="${basedir}"/>
1616
-->
1717

18+
<property name="cacheFile" value="${checkstyle.cache.file}"/>
19+
1820
<!-- Checks that each Java package has a Javadoc file used for commenting. -->
1921
<!-- See http://checkstyle.sf.net/config_javadoc.html#JavadocPackage -->
2022
<!--
@@ -29,6 +31,13 @@
2931

3032
<module name="FileLength"/>
3133

34+
<module name="LineLength">
35+
<property name="max" value="120"/>
36+
<property name="fileExtensions" value="java" />
37+
</module>
38+
39+
<module name="SuppressWithPlainTextCommentFilter"/>
40+
3241
<!-- Following interprets the header file as regular expressions. -->
3342
<!-- <module name="RegexpHeader"/> -->
3443

@@ -60,8 +69,6 @@
6069

6170
<module name="TreeWalker">
6271

63-
<property name="cacheFile" value="${checkstyle.cache.file}"/>
64-
6572
<module name="SuppressWarningsHolder"/>
6673

6774
<!-- Checks for Javadoc comments. -->
@@ -115,9 +122,6 @@
115122

116123
<!-- Checks for Size Violations. -->
117124
<!-- See http://checkstyle.sf.net/config_sizes.html -->
118-
<module name="LineLength">
119-
<property name="max" value="120"/>
120-
</module>
121125
<module name="MethodLength"/>
122126
<module name="ParameterNumber">
123127
<property name="max" value="10"/>

parent/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
<org.apache.maven.plugins.enforcer.version>3.0.0-M1</org.apache.maven.plugins.enforcer.version>
2525
<org.apache.maven.plugins.surefire.version>3.0.0-M3</org.apache.maven.plugins.surefire.version>
2626
<org.apache.maven.plugins.javadoc.version>3.1.0</org.apache.maven.plugins.javadoc.version>
27-
<com.puppycrawl.tools.checkstyle.version>8.18</com.puppycrawl.tools.checkstyle.version>
27+
<com.puppycrawl.tools.checkstyle.version>8.29</com.puppycrawl.tools.checkstyle.version>
2828
<add.release.arguments />
2929
<forkCount>1</forkCount>
3030
<assertj.version>3.11.1</assertj.version>
@@ -129,7 +129,7 @@
129129
<plugin>
130130
<groupId>org.apache.maven.plugins</groupId>
131131
<artifactId>maven-checkstyle-plugin</artifactId>
132-
<version>3.0.0</version>
132+
<version>3.1.0</version>
133133
<configuration>
134134
<configLocation>${basedir}/../etc/checkstyle.xml</configLocation>
135135
<consoleOutput>true</consoleOutput>

0 commit comments

Comments
 (0)