maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wayne Fay <wayne...@gmail.com>
Subject Re: excluding a file inside a jar while building a war file
Date Fri, 27 Apr 2012 20:20:15 GMT
>  hi, i am trying to build a war file . Now  is there a way by which
> one can exclude certain files from a jar which is included inside this
> war ?

Yes but it is a hassle (with dependency:unpack and assembly etc).

> e.g  for building a war file say sample.war , i include myjar.jar as a
> dependency but want to exclude myjar.jar/somefolder/somefile in it
> inside this war, so is this possible?

As Hilco already stated, you should include that file in its own
artifact, then depend (or not) on it directly where it is needed,
instead of getting yourself into this difficult position with having
to pull it out when building some other artifacts that should not
include it.

Wayne

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Mime
View raw message