maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Edelson, Justin" <Justin.Edel...@mtvstaff.com>
Subject RE: How to exclude a package from compile
Date Sat, 17 Jan 2009 13:28:38 GMT
Excluding the pom file can be done with this configuration of the jar plugin:
<configuration>
  <archive>
    <addMavenDescriptor>false</addMavenDescriptor>
  </archive>
</configuration>
 
As for your java package question, I would suggest building this one package as a separate
project and included it (and it's dependencies) into your development war through a profile.
If you can't do this for some reason, then you would need to use the excludes configuration
element of the compiler plugin. I think you tried this, but used the wrong syntax. AFAIK,
paths for excludes are relative from the source root.
 
Justin

________________________________

From: Peter Horlock [mailto:peter.horlock@googlemail.com]
Sent: Sat 1/17/2009 5:30 AM
To: Maven Users List
Subject: Re: How to exclude a package from compile



> I've got a java package (along with the jar dependencies it uses) that I
do
> not want to be added to the war file we send to our client. Also, I do not
> want the pom.xml to be part of the war file.

Actually, to be more precise, the best would be if all classes in the
package would not even be compiled at all - this way I could also exclude
the jar dependency this package uses.
And of course, I also need a way to exclude the pom from the war file.

Thanks in advance,

Peter



Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message