You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by rf...@apache.org on 2019/06/03 17:28:17 UTC
[maven-compiler-plugin] branch master updated: Cleanup debug log
handling
This is an automated email from the ASF dual-hosted git repository.
rfscholte 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 24141bd Cleanup debug log handling
24141bd is described below
commit 24141bda1eff894367585f90aaf573461ac22370
Author: Russell Howe <rh...@siksai.co.uk>
AuthorDate: Mon Jun 3 18:28:12 2019 +0100
Cleanup debug log handling
---
.../apache/maven/plugin/compiler/AbstractCompilerMojo.java | 13 ++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)
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 076a2c6..703b9aa 100644
--- a/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java
+++ b/src/main/java/org/apache/maven/plugin/compiler/AbstractCompilerMojo.java
@@ -859,11 +859,14 @@ public abstract class AbstractCompilerMojo
{
// MCOMPILER-366: if sources contain the module-descriptor it must be used to define the modulepath
sources = getCompileSources( compiler, compilerConfiguration );
-
- getLog().debug( "#sources: " + sources.size() );
- for ( File file : sources )
+
+ if ( getLog().isDebugEnabled() )
{
- getLog().debug( file.getPath() );
+ getLog().debug( "#sources: " + sources.size() );
+ for ( File file : sources )
+ {
+ getLog().debug( file.getPath() );
+ }
}
preparePaths( sources );
@@ -960,7 +963,7 @@ public abstract class AbstractCompilerMojo
}
String[] cl = compiler.createCommandLine( compilerConfiguration );
- if ( getLog().isDebugEnabled() && cl != null && cl.length > 0 )
+ if ( cl != null && cl.length > 0 )
{
StringBuilder sb = new StringBuilder();
sb.append( cl[0] );