This is an automated email from the ASF dual-hosted git repository. sjaranowski pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/maven-compiler-plugin.git
The following commit(s) were added to refs/heads/master by this push: new d0f0bc0 [MCOMPILER-457] Warn about warn-config conflicting values d0f0bc0 is described below commit d0f0bc0ca5d6300ba62cf015581d54a146049e60 Author: Piotrek Żygieło <pzygi...@users.noreply.github.com> AuthorDate: Sat Mar 19 15:40:10 2022 +0100 [MCOMPILER-457] Warn about warn-config conflicting values --- .../java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java b/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java index 58d907d..99793f8 100644 --- a/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java +++ b/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java @@ -732,6 +732,12 @@ public abstract class AbstractCompilerMojo compilerConfiguration.setFailOnWarning( failOnWarning ); + if ( failOnWarning && !showWarnings ) + { + getLog().warn( "The property failOnWarning is set to true, but showWarnings is set to false." ); + getLog().warn( "With compiler's warnings silenced the failOnWarning has no effect." ); + } + compilerConfiguration.setShowDeprecation( showDeprecation ); compilerConfiguration.setSourceVersion( getSource() );