if it is adirect dependencies you can play with <scope> tag, you might use
test or provided scopes. the default scope is compile so that dep will be
included in war.

on the other side if it is a transitive dependency then play with
<exclusions> tag,
in the sample below artifact A is excluded from war.
<dependecy>
    <grouppId>
    <artifactId>...
    <version>...
    <exlusions>
       <exclusion>
            <groupId>G<groupId>
            <artifactId>A</artifactId>
            <version>1.0</version>
       <exclusion>
    </exclusions>
</dependency>


/iulian




On 9/21/06, Lee Meador <[EMAIL PROTECTED]> wrote:

This page

http://maven.apache.org/plugins/maven-war-plugin/examples/war-overlay.html

has information on this as relates directly to the war contents.

You might also want to look into the <scope> tag on your dependencies. I'm
not sure why you would need a jar to compile but not to run the code
itself.
I can see how you would need a jar to compile and run tests but not need
it
for your application code. Putting <scope>test</scope> on the dependency
would  indicate that.

-- Lee

On 9/21/06, Rogerio Baldini <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Is it possible to exclude dependencies from my packaged war file ?
> I mean, I 'd like to remove some jar files from my lib directory because
I
> am not using them in runtime.
>
>
> Thanks,
> Rogerio Baldini.
>
>


--
-- Lee Meador
Sent from gmail. My real email address is lee AT leemeador.com


Reply via email to