google Analytics

Monday, March 7, 2011

Excluding Package from Jar Maven

Maven excluding package from the given jar
======================================================================
<plugin>
<groupId>org.apache.maven.plugins<⁄groupId>
<artifactId>maven-dependency-plugin <⁄artifactId>
<executions> <execution>
<phase>generate-resources<⁄phase> <goals>
<goal>unpack<⁄goal> <⁄goals>
<configuration> <artifactItems> <artifactItem>
<groupId>org.apache.xmlbeans<⁄groupId>
<artifactId>xmlbeans<⁄artifactId>
<version>2.5.0<⁄version> <type>
jar<⁄type>
<excludes>org⁄w3c⁄**<⁄excludes>
<outputDirectory>${project.build.directory}⁄classes<⁄outputDirectory>
<⁄artifactItem> <⁄artifactItems>
<outputDirectory>${project.build.directory}⁄classes<⁄outputDirectory>
<⁄configuration> <⁄execution>
<⁄executions> <⁄plugin>