Add spotless for dubo-distribution
Signed-off-by: crazyhzm <crazyhzm@gmail.com>
This commit is contained in:
parent
c3b0c2eefa
commit
a3096054ed
|
|
@ -27,6 +27,13 @@
|
|||
<artifactId>dubbo-distribution</artifactId>
|
||||
<packaging>pom</packaging>
|
||||
|
||||
<properties>
|
||||
<spotless-maven-plugin.version>2.40.0</spotless-maven-plugin.version>
|
||||
<spotless.action>check</spotless.action>
|
||||
<dubbo-shared-resources.version>1.0.0</dubbo-shared-resources.version>
|
||||
<palantirJavaFormat.version>2.38.0</palantirJavaFormat.version>
|
||||
</properties>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>release</id>
|
||||
|
|
@ -41,7 +48,7 @@
|
|||
<profile>
|
||||
<id>dubbo-all</id>
|
||||
<activation>
|
||||
<activeByDefault>true</activeByDefault>
|
||||
<jdk>[8,)</jdk>
|
||||
</activation>
|
||||
<modules>
|
||||
<module>dubbo-all</module>
|
||||
|
|
@ -55,11 +62,58 @@
|
|||
</modules>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>dubbo-all-shaded</id>
|
||||
<modules>
|
||||
<module>dubbo-all-shaded</module>
|
||||
<module>dubbo-bom</module>
|
||||
</modules>
|
||||
<id>java11+</id>
|
||||
<activation>
|
||||
<jdk>[11,)</jdk>
|
||||
</activation>
|
||||
<build>
|
||||
<!--- newer versions of plugins requires JDK 11 -->
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>com.diffplug.spotless</groupId>
|
||||
<artifactId>spotless-maven-plugin</artifactId>
|
||||
<version>${spotless-maven-plugin.version}</version>
|
||||
<configuration>
|
||||
<java>
|
||||
<palantirJavaFormat>
|
||||
<version>${palantirJavaFormat.version}</version>
|
||||
</palantirJavaFormat>
|
||||
<removeUnusedImports />
|
||||
<importOrder>
|
||||
<file>dubbo-importorder.txt</file>
|
||||
</importOrder>
|
||||
<licenseHeader>
|
||||
<file>checkstyle-header.txt</file>
|
||||
</licenseHeader>
|
||||
</java>
|
||||
<pom>
|
||||
<sortPom>
|
||||
<expandEmptyElements>false</expandEmptyElements>
|
||||
<spaceBeforeCloseEmptyElement>true</spaceBeforeCloseEmptyElement>
|
||||
</sortPom>
|
||||
</pom>
|
||||
<upToDateChecking>
|
||||
<enabled>true</enabled>
|
||||
</upToDateChecking>
|
||||
</configuration>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>dubbo-shared-resources</artifactId>
|
||||
<version>${dubbo-shared-resources.version}</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<executions>
|
||||
<execution>
|
||||
<goals>
|
||||
<goal>${spotless.action}</goal>
|
||||
</goals>
|
||||
<phase>process-sources</phase>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
</profiles>
|
||||
</project>
|
||||
|
|
|
|||
Loading…
Reference in New Issue