You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Karl-Heinz Marbaise (JIRA)" <ji...@codehaus.org> on 2014/09/05 00:07:10 UTC

[jira] (MDEP-451) Regression: mvn dependency:copy doesn't run under maven 3.x multi-module project

    [ https://jira.codehaus.org/browse/MDEP-451?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=352321#comment-352321 ] 

Karl-Heinz Marbaise commented on MDEP-451:
------------------------------------------

The fix for the problem is easy:
{code}
Index: src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java
===================================================================
--- src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java	(revision 1622302)
+++ src/main/java/org/apache/maven/plugin/dependency/fromConfiguration/CopyMojo.java	(working copy)
@@ -37,7 +37,7 @@
  * @version $Id$
  * @since 1.0
  */
-@Mojo( name = "copy", defaultPhase = LifecyclePhase.PROCESS_SOURCES, requiresProject = false, threadSafe = true  )
+@Mojo( name = "copy", defaultPhase = LifecyclePhase.PROCESS_SOURCES, requiresProject = true, threadSafe = true  )
 public class CopyMojo
     extends AbstractFromConfigurationMojo
{code}

The problem is that dependency:copy goal is intended to work outside the life cycle and outside off the project context. So i don't see a chance to change the current behaviour. But what i could imagine is to create a separate goal like copy-with-project.

> Regression: mvn dependency:copy doesn't run under maven 3.x multi-module project
> --------------------------------------------------------------------------------
>
>                 Key: MDEP-451
>                 URL: https://jira.codehaus.org/browse/MDEP-451
>             Project: Maven Dependency Plugin
>          Issue Type: Bug
>          Components: copy
>    Affects Versions: 2.8
>         Environment: All
>            Reporter: Lenny Primak
>            Priority: Critical
>         Attachments: deptest.tar
>
>
> I have a muldi-module project,
> running mvn dependency:copy on root project just runs
> on root project without recursing into the modules.
> This works under maven 3.0.3 but doesn't run at all in the
> current 3.2.2 version of maven



--
This message was sent by Atlassian JIRA
(v6.1.6#6162)