Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable spotless for automatic code formatting #505

Merged
merged 2 commits into from
Jul 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 51 additions & 36 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>

<!--
#%L
License Maven Plugin
Expand All @@ -21,7 +20,6 @@
<http://www.gnu.org/licenses/lgpl-3.0.html>.
#L%
-->

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

Expand All @@ -39,6 +37,7 @@
<description>Maven plugin to download and collect license files from project dependencies.</description>
<url>https://www.mojohaus.org/license-maven-plugin</url>
<inceptionYear>2010</inceptionYear>

<licenses>
<license>
<name>The GNU Lesser General Public License, Version 3.0</name>
Expand All @@ -51,11 +50,11 @@
<developer>
<name>Tony Chemit</name>
<email>[email protected]</email>
<organization>Ultreia.io</organization>
<organizationUrl>https://www.ultreia.io</organizationUrl>
<roles>
<role>Lead Developer</role>
</roles>
<organization>Ultreia.io</organization>
<organizationUrl>https://www.ultreia.io</organizationUrl>
<timezone>Europe/Paris</timezone>
</developer>
<developer>
Expand Down Expand Up @@ -93,20 +92,23 @@
<scm>
<connection>scm:git:https://github.com/mojohaus/license-maven-plugin.git</connection>
<developerConnection>scm:git:ssh://[email protected]/mojohaus/license-maven-plugin.git</developerConnection>
<url>https://github.com/mojohaus/license-maven-plugin/tree/master</url>
<tag>HEAD</tag>
<url>https://github.com/mojohaus/license-maven-plugin/tree/master</url>
</scm>

<issueManagement>
<system>github</system>
<url>https://github.com/mojohaus/license-maven-plugin/issues/</url>
</issueManagement>

<ciManagement>
<system>github</system>
<url>https://github.com/mojohaus/license-maven-plugin/actions</url>
</ciManagement>

<properties>
<mavenVersion>3.5.4</mavenVersion>
<recommendedJavaBuildVersion>11</recommendedJavaBuildVersion>
<mojo.java.target>8</mojo.java.target>

<processorVersion>1.3</processorVersion>
Expand Down Expand Up @@ -335,6 +337,13 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<configuration>
<!-- TODO enable with spotless -->
<skip>true</skip>
<headerLocation>config/checkstyle-header.txt</headerLocation>
<excludes>**/HelpMojo.java,**/SpdxLicenseListData.java</excludes>
<!-- these are generated -->
</configuration>
<executions>
<execution>
<id>checkstyle-check</id>
Expand All @@ -344,30 +353,24 @@
<phase>verify</phase>
</execution>
</executions>
<configuration>
<!-- TODO enable with spotless -->
<skip>true</skip>
<headerLocation>config/checkstyle-header.txt</headerLocation>
<excludes>**/HelpMojo.java,**/SpdxLicenseListData.java</excludes><!-- these are generated -->
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-maven-plugin</artifactId>
<executions>
<execution>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
<configuration>
<signature>
<groupId>org.codehaus.mojo.signature</groupId>
<artifactId>java17</artifactId>
<version>1.0</version>
</signature>
</configuration>
<executions>
<execution>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.eclipse.sisu</groupId>
Expand All @@ -377,6 +380,13 @@
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<dependencies>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${version.httpcomponents.httpclient}</version>
</dependency>
</dependencies>
<executions>
<execution>
<!-- Not bound to any phase. Invoke manually using -->
Expand All @@ -391,13 +401,6 @@
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>${version.httpcomponents.httpclient}</version>
</dependency>
</dependencies>
</plugin>

</plugins>
Expand All @@ -423,10 +426,10 @@
<executions>
<execution>
<id>attach-artifacts</id>
<phase>package</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<phase>package</phase>
<configuration>
<artifacts>
<artifact>
Expand All @@ -443,6 +446,13 @@
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<dependencies>
<dependency>
<groupId>org.littleshoot</groupId>
<artifactId>littleproxy</artifactId>
<version>1.1.2</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>LittleProxyStart</id>
Expand All @@ -465,13 +475,6 @@
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.littleshoot</groupId>
<artifactId>littleproxy</artifactId>
<version>1.1.2</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<artifactId>maven-invoker-plugin</artifactId>
Expand Down Expand Up @@ -551,6 +554,7 @@
<settingsFile>src/it/settings.xml</settingsFile>
<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
</configuration>
<dependencies />
<executions>
<execution>
<id>one-integration-test</id>
Expand All @@ -566,9 +570,6 @@
</configuration>
</execution>
</executions>
<dependencies>

</dependencies>
</plugin>
</plugins>
</build>
Expand Down Expand Up @@ -617,5 +618,19 @@
</plugins>
</reporting>
</profile>
<profile>
<id>java11+</id>
<activation>
<jdk>[11,)</jdk>
</activation>
<build>
<plugins>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
Loading