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 2020/03/29 20:04:57 UTC

[maven] 06/17: Only use module output directory when it has been compiled in this session

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

rfscholte pushed a commit to branch MNG-4660
in repository https://gitbox.apache.org/repos/asf/maven.git

commit 3274c2359d559e19a297dcfc2e7a26ec6f42f997
Author: Maarten Mulders <ma...@infosupport.com>
AuthorDate: Fri Feb 14 15:18:30 2020 +0100

    Only use module output directory when it has been compiled in this session
---
 maven-core/src/main/java/org/apache/maven/ReactorReader.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/maven-core/src/main/java/org/apache/maven/ReactorReader.java b/maven-core/src/main/java/org/apache/maven/ReactorReader.java
index 7c52ff2..2bfb9ee 100644
--- a/maven-core/src/main/java/org/apache/maven/ReactorReader.java
+++ b/maven-core/src/main/java/org/apache/maven/ReactorReader.java
@@ -183,7 +183,7 @@ class ReactorReader
             else
             {
                 String type = artifact.getProperty( "type", "" );
-                if ( COMPILE_PHASE_TYPES.contains( type ) )
+                if ( project.hasLifecyclePhase( "compile" ) && COMPILE_PHASE_TYPES.contains( type ) )
                 {
                     return new File( project.getBuild().getOutputDirectory() );
                 }