Fred Bricon created MSHARED-324:
-----------------------------------

             Summary: Archiver zips duplicate pom.xml and properties files
                 Key: MSHARED-324
                 URL: https://jira.codehaus.org/browse/MSHARED-324
             Project: Maven Shared Components
          Issue Type: Bug
          Components: maven-archiver
    Affects Versions: maven-archiver-2.5
            Reporter: Fred Bricon
         Attachments: duplicate-zipped-files.zip

Several users of m2e-wtp complained invoking *mvn package* (without clean) on 
their project generates a jar containing duplicate pom.properties and pom.xml.

* 
http://stackoverflow.com/questions/10308916/maven-generates-duplicate-pom-xml-and-pom-properties-files-in-a-jar
* http://dev.eclipse.org/mhonarc/lists/m2e-users/msg01995.html
* https://issues.sonatype.org/browse/MECLIPSEWTP-209
* https://issuetracker.springsource.com/browse/STS-2349
* https://github.com/sonatype/m2eclipse-extras/issues/9
* https://bugs.eclipse.org/bugs/show_bug.cgi?id=405915

This is caused by m2eclipse-mavenarchiver generating these files during eclipse 
incremental builds, under target/classes.

The proper course of action is generally to invoke mvn clean package, in that 
case, but I believe the archiver should never generate zips with duplicate 
entries in the first place.

I don't have an opinion whether the mavenarchiver generated files should take 
precedence over the existing ones, or the other way around. Whatever solution 
is chosen, a warning should be logged in case of duplicates.



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

Reply via email to