Skip to content

Commit

Permalink
Use EEAs with maven-compiler-plugin
Browse files Browse the repository at this point in the history
Using this configuration the maven-compiler-plugin will also use the Eclipse External Annotations.
This results in more similar build results when not using Eclipse like CI, on the CLI and when using other IDEs.

Signed-off-by: Wouter Born <github@maindrain.net>
  • Loading branch information
wborn committed Aug 26, 2023
1 parent a08c347 commit 31a4f76
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,10 @@ Import-Package: \\
<configuration>
<compilerId>eclipse</compilerId>
<compilerArgs>
<arg>-annotationpath</arg>
<arg>CLASSPATH</arg>
<arg>-classpath</arg>
<arg>${project.build.directory}/dependency</arg>
<arg>-err:+nullAnnot(org.eclipse.jdt.annotation.Nullable|org.eclipse.jdt.annotation.NonNull|org.eclipse.jdt.annotation.NonNullByDefault),+inheritNullAnnot,+nullAnnotConflict,-nullUncheckedConversion</arg>
<arg>-warn:+null,+inheritNullAnnot,+nullAnnotConflict,-nullUncheckedConversion,+nullAnnotRedundant,+nullDereference</arg>
</compilerArgs>
Expand Down

0 comments on commit 31a4f76

Please sign in to comment.