Separate nottp checkstyle configuration

See gh-16682
1.5.x
Andy Wilkinson 6 years ago committed by Phillip Webb
parent ede197fa55
commit fb24b5a684

@ -64,7 +64,6 @@
<artifactId>replacer</artifactId>
<version>1.5.3</version>
</plugin>
</plugins>
</pluginManagement>
</build>

@ -539,6 +539,40 @@
<configLocation>src/checkstyle/checkstyle.xml</configLocation>
<suppressionsLocation>src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
<includeTestSourceDirectory>true</includeTestSourceDirectory>
</configuration>
<goals>
<goal>check</goal>
</goals>
</execution>
<execution>
<id>nohttp-checkstyle-validation</id>
<phase>validate</phase>
<configuration>
<skip>${disable.checks}</skip>
<configLocation>src/checkstyle/nohttp-checkstyle.xml</configLocation>
<suppressionsLocation>src/checkstyle/nohttp-checkstyle-suppressions.xml</suppressionsLocation>
<propertyExpansion>main.basedir=${main.basedir}</propertyExpansion>
<sourceDirectories>./</sourceDirectories>
<includes>**/*</includes>
<excludes>.git/**/*,target/**/*</excludes>
</configuration>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<executions>
<execution>
<id>nohttp-checkstyle-validation</id>
<phase>validate</phase>
<configuration>
<skip>${disable.checks}</skip>
<configLocation>src/checkstyle/nohttp-checkstyle.xml</configLocation>
<suppressionsLocation>src/checkstyle/nohttp-checkstyle-suppressions.xml</suppressionsLocation>
<propertyExpansion>main.basedir=${main.basedir}</propertyExpansion>
<sourceDirectories>./</sourceDirectories>
<includes>**/*</includes>

@ -3,11 +3,7 @@
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
<suppressions>
<suppress files="[\\/]transaction-logs[\\/]" checks=".*" />
<suppress files="[\\/]target[\\/]" checks=".*" />
<suppress files="[\\/]build.log" checks=".*" />
<suppress files=".+\.(jar|git|ico|p12)" checks=".*" />
<suppress files="dependency-reduced-pom.xml" checks="NoHttp" />
<suppress files="SpringApplicationTests\.java" checks="FinalClass" />
<suppress files=".+Configuration\.java" checks="HideUtilityClassConstructor" />
<suppress files=".+Application\.java" checks="HideUtilityClassConstructor" />

@ -1,9 +1,6 @@
<?xml version="1.0"?>
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN" "https://checkstyle.org/dtds/configuration_1_2.dtd">
<module name="com.puppycrawl.tools.checkstyle.Checker">
<module name="io.spring.nohttp.checkstyle.check.NoHttpCheck">
<property name="whitelistFileName" value="${main.basedir}/spring-boot-parent/src/checkstyle/nohttp-whitelist.txt"/>
</module>
<module name="io.spring.javaformat.checkstyle.SpringChecks" />
<module name="com.puppycrawl.tools.checkstyle.TreeWalker">
<module name="com.puppycrawl.tools.checkstyle.checks.imports.IllegalImportCheck">

@ -0,0 +1,13 @@
<?xml version="1.0"?>
<!DOCTYPE suppressions PUBLIC
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
<suppressions>
<suppress files="[\\/]transaction-logs[\\/]" checks="NoHttp" />
<suppress files="[\\/]target[\\/]" checks="NoHttp" />
<suppress files="[\\/]build.log" checks="NoHttp" />
<suppress files=".+\.(jar|git|ico|p12|gif|jks|jpg)" checks="NoHttp" />
<suppress files="dependency-reduced-pom.xml" checks="NoHttp" />
<suppress files="jquery.validate.js" checks="NoHttp" />
<suppress files="jquery-[0-9]\.[0-9]\.[0-9].js" checks="NoHttp" />
</suppressions>

@ -0,0 +1,7 @@
<?xml version="1.0"?>
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN" "https://checkstyle.org/dtds/configuration_1_2.dtd">
<module name="com.puppycrawl.tools.checkstyle.Checker">
<module name="io.spring.nohttp.checkstyle.check.NoHttpCheck">
<property name="whitelistFileName" value="${main.basedir}/spring-boot-parent/src/checkstyle/nohttp-whitelist.txt"/>
</module>
</module>

@ -1,2 +1,6 @@
^http://livereload.com/protocols/official-7.*
^http://docs.groovy-lang.org.*
^http://exslt.org/common.*
^http://groovy-lang.org.*
^http://hsqldb.org.*
^http://livereload.com/.*
^http://www.jdotsoft.com.*

@ -171,6 +171,18 @@
<configLocation>../spring-boot-parent/src/checkstyle/checkstyle.xml</configLocation>
<suppressionsLocation>../spring-boot-parent/src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
<includeTestSourceDirectory>true</includeTestSourceDirectory>
</configuration>
<goals>
<goal>check</goal>
</goals>
</execution>
<execution>
<id>nohttp-checkstyle-validation</id>
<phase>validate</phase>
<configuration>
<skip>${disable.checks}</skip>
<configLocation>../spring-boot-parent/src/checkstyle/nohttp-checkstyle.xml</configLocation>
<suppressionsLocation>../spring-boot-parent/src/checkstyle/nohttp-checkstyle-suppressions.xml</suppressionsLocation>
<propertyExpansion>main.basedir=${main.basedir}</propertyExpansion>
<sourceDirectories>./</sourceDirectories>
<includes>**/*</includes>

Loading…
Cancel
Save