[ 
https://issues.apache.org/jira/browse/MDEP-555?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15893170#comment-15893170
 ] 

Thomas Hartwig commented on MDEP-555:
-------------------------------------

It turned out the outputDirectory was configured in the wrong section, instead 
within the execution settings it must be configured as the plugin configuration 
see below. So my report is not valid. Probably it is worth to include a 
complete example in the usage guide: 
https://maven.apache.org/plugins/maven-dependency-plugin/usage.html

{code:xml}
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>3.0.0</version>
                <configuration>
                    <outputDirectory>${project.lib.dir}</outputDirectory>
                </configuration>
                <executions>
                    <execution>
                        <id>copy-dependencies</id>
                        <phase>package</phase>
                        <goals>
                            <goal>copy-dependencies</goal>
                        </goals>
                        <configuration>
                            <overWriteReleases>false</overWriteReleases>
                            <overWriteSnapshots>false</overWriteSnapshots>
                            <overWriteIfNewer>true</overWriteIfNewer>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
{code}

> outputDirectory is not used
> ---------------------------
>
>                 Key: MDEP-555
>                 URL: https://issues.apache.org/jira/browse/MDEP-555
>             Project: Maven Dependency Plugin
>          Issue Type: Bug
>          Components: copy-dependencies
>    Affects Versions: 2.8, 3.0.0
>         Environment: Apache Maven 3.3.9
> Maven home: /usr/share/maven
> Java version: 1.8.0_121, vendor: Oracle Corporation
> Java home: /usr/lib/jvm/java-8-oracle/jre
> Default locale: en_US, platform encoding: UTF-8
> OS name: "linux", version: "4.4.0-64-generic", arch: "amd64", family: "unix"
>            Reporter: Thomas Hartwig
>
> I use the configuration below to be able to copy all dependencies. The 
> problem is the outputDirectory is not used. The files are copied to 
> target/dependency of the project dir instead. Tested in 3.0.0 and 2.8.
> {code:xml}
>                         <configuration>
>                             <outputDirectory>/tmp/</outputDirectory>
>                             
> <!--<outputDirectory>${project.lib.dir}</outputDirectory>-->
>                             <overWriteReleases>false</overWriteReleases>
>                             <overWriteSnapshots>false</overWriteSnapshots>
>                             <overWriteIfNewer>true</overWriteIfNewer>
>                         </configuration>
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to