This is an automated email from the ASF dual-hosted git repository.

iemejia pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/beam.git

commit a340ec17d939c1a016f00ef325d98c931c8ab7bf
Author: Kenneth Knowles <k...@apache.org>
AuthorDate: Mon Feb 12 11:23:29 2018 -0800

    [BEAM-3697] Add Maven profile to run error-prone static analysis
---
 pom.xml | 34 ++++++++++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)

diff --git a/pom.xml b/pom.xml
index d866c85..9a09513 100644
--- a/pom.xml
+++ b/pom.xml
@@ -175,6 +175,8 @@
     <maven-shade-plugin.version>3.1.0</maven-shade-plugin.version>
     
<reproducible-build-maven-plugin.version>0.4</reproducible-build-maven-plugin.version>
     <maven-assembly-plugin.version>3.1.0</maven-assembly-plugin.version>
+    
<plexus-compiler-java-errorprone.version>2.8.2</plexus-compiler-java-errorprone.version>
+    <error_prone_core.version>2.2.0</error_prone_core.version>
 
     <compiler.error.flag>-Werror</compiler.error.flag>
     
<compiler.default.pkginfo.flag>-Xpkginfo:always</compiler.default.pkginfo.flag>
@@ -354,6 +356,38 @@
     </profile>
 
     <profile>
+      <id>errorprone</id>
+      <build>
+        <plugins>
+          <!-- Turn on Error Prone -->
+          <plugin>
+            <groupId>org.apache.maven.plugins</groupId>
+            <artifactId>maven-compiler-plugin</artifactId>
+            <configuration>
+              <compilerId>javac-with-errorprone</compilerId>
+              <forceJavacCompilerUse>true</forceJavacCompilerUse>
+              <showWarnings>true</showWarnings>
+            </configuration>
+            <dependencies>
+              <dependency>
+                <groupId>org.codehaus.plexus</groupId>
+                <artifactId>plexus-compiler-javac-errorprone</artifactId>
+               <version>${plexus-compiler-java-errorprone.version}</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>${error_prone_core.version}</version>
+              </dependency>
+            </dependencies>
+          </plugin>
+        </plugins>
+      </build>
+    </profile>
+
+    <profile>
       <id>build-containers</id>
       <build>
         <!-- TODO(BEAM-2878): enable container build for releases -->

-- 
To stop receiving notification emails like this one, please contact
ieme...@apache.org.

Reply via email to