Skip to content
Snippets Groups Projects
Commit 20fcfd7f authored by Daniel Gultsch's avatar Daniel Gultsch
Browse files

add maven spotless plugin for code formatting

parent 07f17c5d
No related merge requests found
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" <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">
xmlns="http://maven.apache.org/POM/4.0.0"
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> <modelVersion>4.0.0</modelVersion>
<repositories> <groupId>QuicksyServer</groupId>
<repository> <artifactId>im.quicksy.server</artifactId>
<id>jitpack.io</id> <version>0.3</version>
<url>https://jitpack.io</url>
</repository>
</repositories>
<dependencies> <dependencies>
...@@ -139,9 +134,12 @@ ...@@ -139,9 +134,12 @@
</dependencies> </dependencies>
<groupId>QuicksyServer</groupId> <repositories>
<artifactId>im.quicksy.server</artifactId> <repository>
<version>0.3</version> <id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
<build> <build>
<plugins> <plugins>
...@@ -151,18 +149,16 @@ ...@@ -151,18 +149,16 @@
<version>3.2.0</version> <version>3.2.0</version>
<executions> <executions>
<execution> <execution>
<phase>package</phase>
<goals> <goals>
<goal>shade</goal> <goal>shade</goal>
</goals> </goals>
<phase>package</phase>
<configuration> <configuration>
<transformers> <transformers>
<transformer <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<mainClass>im.quicksy.server.Main</mainClass> <mainClass>im.quicksy.server.Main</mainClass>
</transformer> </transformer>
<transformer <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"></transformer>
implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer"/>
</transformers> </transformers>
<minimizeJar>false</minimizeJar> <minimizeJar>false</minimizeJar>
</configuration> </configuration>
...@@ -179,8 +175,38 @@ ...@@ -179,8 +175,38 @@
<target>11</target> <target>11</target>
</configuration> </configuration>
</plugin> </plugin>
<plugin>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
<version>2.17.2</version>
<configuration>
<java>
<googleJavaFormat>
<version>1.8</version>
<style>AOSP</style>
<reflowLongStrings>true</reflowLongStrings>
</googleJavaFormat>
</java>
<pom>
<sortPom>
<nrOfIndentSpace>4</nrOfIndentSpace>
<!-- same as google java format AOSP -->
</sortPom>
</pom>
</configuration>
<executions>
<execution>
<!-- Runs in compile phase to fail fast in case of formatting issues.-->
<id>spotless-check</id>
<goals>
<goal>check</goal>
</goals>
<phase>compile</phase>
</execution>
</executions>
</plugin>
</plugins> </plugins>
</build> </build>
</project>
</project>
\ No newline at end of file
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment