Last active
July 5, 2018 03:23
-
-
Save yangl/096cc20c7d48aff48281690937aa65f1 to your computer and use it in GitHub Desktop.
Error Prone Maven 使用例子 https://errorprone.info/docs/installation https://github.com/google/error-prone
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<build> | |
<plugins> | |
<plugin> | |
<groupId>org.apache.maven.plugins</groupId> | |
<artifactId>maven-compiler-plugin</artifactId> | |
<version>3.7.0</version> | |
<configuration> | |
<compilerId>javac-with-errorprone</compilerId> | |
<forceJavacCompilerUse>true</forceJavacCompilerUse> | |
<!-- maven-compiler-plugin defaults to targeting Java 5, but our javac | |
only supports >=6 --> | |
<source>8</source> | |
<target>8</target> | |
</configuration> | |
<dependencies> | |
<dependency> | |
<groupId>org.codehaus.plexus</groupId> | |
<artifactId>plexus-compiler-javac-errorprone</artifactId> | |
<version>2.8.4</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.3.1</version> | |
</dependency> | |
</dependencies> | |
</plugin> | |
</plugins> | |
</build> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment