Details
Description
Using Maven 2.2.1, the maven-dependency-plugin copy goal always copied the artifacts from the local .m2, which meant that they kept their full name (ex: ccad-moda-1.0.0-SNAPSHOT-system-help.pdf). Using Maven 3.0-beta-1, this is no longer always the case. If I build just the assembly sub-module, then it copies the artifact from the local .m2 and maintains the name. If I build the whole project, which includes building the module that produces the artifact being copied, then Maven 3 skips going to the local .m2 and instead goes back to the original source of the artifact and copies it from there. This results in a copied file with the short name (ex: system-help.pdf).
Here are some lines from the build logs to show the difference.
Maven 2.2.1
===========
[INFO] Configured Artifact: com.ccadllc.test1:ccad-moda:system-help:1.0.0-SNAPSHOT:pdf
[DEBUG] Skipping disabled repository central
[DEBUG] ccad-moda: using locally installed snapshot
[INFO] Copying /home/jzuidema/.m2/repository/com/ccadllc/test1/ccad-moda/1.0.0-SNAPSHOT/ccad-moda-1.0.0-SNAPSHOT-system-help.pdf to /extra1/export/home/jzuidema/tmp2/test1/assembly/target/pdfs/ccad-moda-1.0.0-SNAPSHOT-system-help.pdf
Maven 3.0-beta-1
================
[INFO] Configured Artifact: com.ccadllc.test1:ccad-moda:system-help:1.0.0-SNAPSHOT:pdf
[INFO] Copying /extra1/export/home/jzuidema/tmp2/test1/moda/system-help.pdf to /extra1/export/home/jzuidema/tmp2/test1/assembly/target/pdfs/system-help.pdf
Attached is an example project with the build logs from a maven 2.2.1 and a 3.0-beta-1 run of "mvn -X clean install" at the top level of the project.