[ 
http://jira.codehaus.org/browse/MASSEMBLY-217?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=148400#action_148400
 ] 

John Casey commented on MASSEMBLY-217:
--------------------------------------

FWIW, you can now gain a little more control over this using 
2.2-beta-3-SNAPSHOT latest code. The fix for MASSEMBLY-285 will also fix this, 
particularly if you set:

{code:xml}
<archiverConfig>
  <duplicateBehavior>fail</duplicateBehavior>
</archiverConfig>
{code}

Admittedly, we could probably find a better way of providing a better message 
for specific instances where mapped artifact file names overlap, but it would 
be a little confusing if a mapped artifact filename overlapped with another 
file in the archive that wasn't the result of outputFileNameMapping logic.

> <outputFileNameMapping> needs to report collision.
> --------------------------------------------------
>
>                 Key: MASSEMBLY-217
>                 URL: http://jira.codehaus.org/browse/MASSEMBLY-217
>             Project: Maven 2.x Assembly Plugin
>          Issue Type: Bug
>    Affects Versions: 2.2-beta-1
>            Reporter: Kohsuke Kawaguchi
>             Fix For: 2.2-beta-3
>
>         Attachments: massembly-217.patch
>
>
> If <outputFileNameMapping> maps two or more artifacts into the same name, it 
> needs to be reported as an error.
> Maven currently just takes the last one without reporting anything, and as a 
> result I didn't notice that my assembly descriptor had a problem until I 
> debug the plugin source code.
> This problem is particularly made worse by a broken jar-with-dependencies 
> example in [the 
> documentation|http://maven.apache.org/plugins/maven-assembly-plugin/descriptor-refs.html],
>  which says:
> {noformat}
>   <dependencySets>
>     <dependencySet>
>       <outputDirectory></outputDirectory>
>       <outputFileNameMapping></outputFileNameMapping>
>       <unpack>true</unpack>
>       <scope>runtime</scope>
>     </dependencySet>
>   </dependencySets>
> {noformat}
> ... which maps every dependency to ""

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to