you can exclude files by specifying a filter Here is a working filter from pom. It filters out all META_INF/LICENSE files from all dependencies.
thanks Arun <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> <executions> <execution> <phase>package</phase> <goals> <goal>shade</goal> </goals> <configuration> <transformers> <transformer implementation="org.apache.maven.plugins.shade.resource.ComponentsXmlResourceTransformer" /> </transformers> <filters> <filter> <artifact>*:*</artifact> <excludes> <exclude>META-INF/LICENSE</exclude> </excludes> </filter> </filters> </configuration> </execution> </executions> </plugin>.. On Wed, Jan 11, 2012 at 12:01 PM, vvkbtnkr <vvkbt...@yahoo.com> wrote: > I am new to maven and am stuck in what might be a very simple issue and > need > help ... I am trying to create an uber jar using shade and am trying to > remove some txt, license files from the final jar, but some how it does not > seem to work. Here is the relevant section from my pom.xml > > > > > when the jar is created and I try to look into the jar, i see the files > above in jar. Tried playing around with the configuration options, but > nothing seems to be working. I ran maven in -X (debug) mode and can see > statements like - > > and > > > However, when I look into the jar, here is what I see: > > > All files that I want removed are still there. Additionally the target > folder has two jars "sc-1.0.jar" which is the uber jar and > "original-sc-1.0.jar" which is the much smaller original jar. What is it > that I am doing wrong here? > Thanks, > Vivek > > -- > View this message in context: > http://maven-users.828.n2.nabble.com/help-on-shade-plugin-tp7177703p7177703.html > Sent from the maven users mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: users-unsubscr...@maven.apache.org > For additional commands, e-mail: users-h...@maven.apache.org > >