[ 
https://issues.apache.org/jira/browse/MDEP-430?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Osipov closed MDEP-430.
-------------------------------
    Resolution: Auto Closed

This issue has been auto closed because it has been inactive for a long period 
of time. If you think this issue still applies, retest your problem with the 
most recent version of Maven and the affected component, reopen and post your 
results.

> Dependency plugin does not seem to respect profile specific copy goals
> ----------------------------------------------------------------------
>
>                 Key: MDEP-430
>                 URL: https://issues.apache.org/jira/browse/MDEP-430
>             Project: Maven Dependency Plugin
>          Issue Type: Bug
>          Components: copy
>    Affects Versions: 2.1
>         Environment: Mac OSX Mountain Lion 10.8.4
>            Reporter: Kamaldeep Tumkur
>            Priority: Major
>
> I am using the dependency plugin inside a swf type project that builds using 
> Maven. Ant is currently being used to copy the target files to the 
> destination directories, but my hope is to use the dependency plugin so that 
> everything is included inside the POM.
> Here's my rough POM structure:
> <!-- Below build properties are listed outside of 'profile' since they are 
> not supported inside a 'profile' tag. 
> <build>
>     <sourceDirectory>dir</sourceDirectory>
>     <finalName>${project.name}</finalName>
> </build>
> <profiles>
> <profile>
> <id>profile1</id>
> <build>
> <plugins>
> <plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-dependency-plugin</artifactId>
>    .
>    <goal>copy</goal>
>    .
>   <configuration> ... </configuration>
>   <outputDirectory>DIR1</outputDirectory>
> </plugin>
> </plugins>
> </build>
> </profile>
> <profile>
> <id>profile2</id>
> <build>
> <plugins>
> <plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-dependency-plugin</artifactId>
>    .
>    <goal>copy</goal>
>    .
>   <configuration> ... </configuration>
>   <outputDirectory>DIR2</outputDirectory>
> </plugin>
> </plugins>
> </build>
> </profile>
> </profiles>
> What I am seeing:
> When I run: 'mvn -U clean install -P profile1', the execution for profile1 
> proceeds and the files are copied to DIR1 as expected.
> When I run: 'mvn -U clean install -P profile2', the execution for profile1 
> and profile2 both happen and the file meant to go into DIR2 is also copied 
> into DIR1. This is undesirable.
> Please let me know if any further details may be helpful here. Thanks for 
> your time.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to