Browse Source

Enable error-prone for the Maven build

- update maven-compiler-plugin to 3.6.0
- exclude InsecureCipherFactory from errorprone checks

See
https://maven.apache.org/guides/mini/guide-default-execution-ids.html#Example:_Configuring_compile_to_run_twice
https://groups.google.com/d/topic/error-prone-discuss/pzT45ZMCQOc/discussion

Change-Id: Ic16d3f15cf2ef40de62fe6bfe4b8b35f0c1edc4e
Signed-off-by: David Pursehouse <david.pursehouse@gmail.com>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
tags/v4.6.0.201612231935-r
David Pursehouse 7 years ago
parent
commit
872adb71dc
1 changed files with 48 additions and 1 deletions
  1. 48
    1
      pom.xml

+ 48
- 1
pom.xml View File

@@ -258,12 +258,59 @@

<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.5.1</version>
<version>3.6.0</version>
<configuration>
<encoding>UTF-8</encoding>
<source>1.8</source>
<target>1.8</target>
</configuration>
<executions>
<execution>
<id>default-compile</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<includes>
<include>org/eclipse/jgit/transport/InsecureCipherFactory.java</include>
</includes>
</configuration>
</execution>
<execution>
<id>compile-with-errorprone</id>
<phase>compile</phase>
<goals>
<goal>compile</goal>
</goals>
<configuration>
<compilerId>javac-with-errorprone</compilerId>
<forceJavacCompilerUse>true</forceJavacCompilerUse>
<excludes>
<exclude>org/eclipse/jgit/transport/InsecureCipherFactory.java</exclude>
</excludes>
</configuration>
</execution>
</executions>
<dependencies>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-compiler-javac</artifactId>
<version>2.8.1</version>
</dependency>
<dependency>
<groupId>org.codehaus.plexus</groupId>
<artifactId>plexus-compiler-javac-errorprone</artifactId>
<version>2.8.1</version>
</dependency>
<!-- override plexus-compiler-javac-errorprone's dependency on
Error Prone with the latest version -->
<dependency>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_core</artifactId>
<version>2.0.14</version>
</dependency>
</dependencies>
</plugin>

<plugin>

Loading…
Cancel
Save