1 Reply Latest reply on Sep 19, 2006 6:04 PM by ryan.campbell

    Maven annoyances

    anil.saldhana

      Ok, the default maven jar plugin adds lots of junk to the created jar file like META-INF/maven/pom.xml etc (reasoning: jar files are self describing about the maven versioning or something like that)

      You will need to define:
       <plugins>
       <plugin>
       <groupId>org.apache.maven.plugins</groupId>
       <artifactId>maven-jar-plugin</artifactId>
       <version>2.1</version>
       <configuration>
       <archive>
       <addMavenDescriptor>false</addMavenDescriptor>
       </archive>
       </configuration>
       </plugin>
       </plugins>
      


      in your build element in the pom.xml, to have your generated jar files free from maven metadata.

      http://maven.apache.org/guides/mini/guide-archive-configuration.html