How to exclude jars generated by maven war plugin ?
- by Jacques René Mesrine
Because of transitive dependencies, my wars are getting populated by xml-apis, xerces jars.
I tried following the instructions on the reference page for maven-war-plugin but it is not working.
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<packagingExcludes>WEB-INF/lib/xalan-2.6.0.jar,WEB-INF/lib/xercesImpl-2.6.2.jar,WEB-INF/lib/xml-apis-1.0.b2.jar,WEB-INF/lib/xmlParserAPIs-2.6.2.jar</packagingExcludes>
<webXml>${basedir}/src/main/webapp/WEB-INF/web.xml</webXml>
<warName>project1</warName>
<warSourceDirectory>src/main/webapp</warSourceDirectory>
</configuration>
</plugin>
What am I doing wrong ?
If it matters, I discovered that the maven-war-plugin I'm using is at version 2.1-alpha-1