mirror of
https://github.com/spring-projects/spring-boot.git
synced 2024-07-15 01:07:30 +08:00
Separate nottp checkstyle configuration
See gh-16682
This commit is contained in:
parent
ede197fa55
commit
fb24b5a684
1
pom.xml
1
pom.xml
@ -64,7 +64,6 @@
|
|||||||
<artifactId>replacer</artifactId>
|
<artifactId>replacer</artifactId>
|
||||||
<version>1.5.3</version>
|
<version>1.5.3</version>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|
||||||
</plugins>
|
</plugins>
|
||||||
</pluginManagement>
|
</pluginManagement>
|
||||||
</build>
|
</build>
|
||||||
|
@ -539,6 +539,40 @@
|
|||||||
<configLocation>src/checkstyle/checkstyle.xml</configLocation>
|
<configLocation>src/checkstyle/checkstyle.xml</configLocation>
|
||||||
<suppressionsLocation>src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
|
<suppressionsLocation>src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
|
||||||
<includeTestSourceDirectory>true</includeTestSourceDirectory>
|
<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>
|
<propertyExpansion>main.basedir=${main.basedir}</propertyExpansion>
|
||||||
<sourceDirectories>./</sourceDirectories>
|
<sourceDirectories>./</sourceDirectories>
|
||||||
<includes>**/*</includes>
|
<includes>**/*</includes>
|
||||||
|
@ -3,11 +3,7 @@
|
|||||||
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
|
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
|
||||||
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
|
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
|
||||||
<suppressions>
|
<suppressions>
|
||||||
<suppress files="[\\/]transaction-logs[\\/]" checks=".*" />
|
|
||||||
<suppress files="[\\/]target[\\/]" 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="SpringApplicationTests\.java" checks="FinalClass" />
|
||||||
<suppress files=".+Configuration\.java" checks="HideUtilityClassConstructor" />
|
<suppress files=".+Configuration\.java" checks="HideUtilityClassConstructor" />
|
||||||
<suppress files=".+Application\.java" checks="HideUtilityClassConstructor" />
|
<suppress files=".+Application\.java" checks="HideUtilityClassConstructor" />
|
||||||
|
@ -1,9 +1,6 @@
|
|||||||
<?xml version="1.0"?>
|
<?xml version="1.0"?>
|
||||||
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN" "https://checkstyle.org/dtds/configuration_1_2.dtd">
|
<!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="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="io.spring.javaformat.checkstyle.SpringChecks" />
|
||||||
<module name="com.puppycrawl.tools.checkstyle.TreeWalker">
|
<module name="com.puppycrawl.tools.checkstyle.TreeWalker">
|
||||||
<module name="com.puppycrawl.tools.checkstyle.checks.imports.IllegalImportCheck">
|
<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>
|
7
spring-boot-parent/src/checkstyle/nohttp-checkstyle.xml
Normal file
7
spring-boot-parent/src/checkstyle/nohttp-checkstyle.xml
Normal file
@ -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://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>
|
<configLocation>../spring-boot-parent/src/checkstyle/checkstyle.xml</configLocation>
|
||||||
<suppressionsLocation>../spring-boot-parent/src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
|
<suppressionsLocation>../spring-boot-parent/src/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
|
||||||
<includeTestSourceDirectory>true</includeTestSourceDirectory>
|
<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>
|
<propertyExpansion>main.basedir=${main.basedir}</propertyExpansion>
|
||||||
<sourceDirectories>./</sourceDirectories>
|
<sourceDirectories>./</sourceDirectories>
|
||||||
<includes>**/*</includes>
|
<includes>**/*</includes>
|
||||||
|
Loading…
Reference in New Issue
Block a user