You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Wright, Omari" <Om...@solers.com> on 2012/08/14 17:53:29 UTC

Properties file exlusion from dependency

Is this possible? If so, how can I do it?

Re: Properties file exlusion from dependency

Posted by Laird Nelson <lj...@gmail.com>.
On Tue, Aug 14, 2012 at 8:53 AM, Wright, Omari <Om...@solers.com>wrote:

> Is this possible? If so, how can I do it?
>

You might be asking:

"I depend on an artifact.  It has a properties file in it that gets read or
is otherwise present on the classpath.  This interferes with my system.  I
would like to continue depending on the artifact, but somehow without the
properties file."

If so:

If you depend on an artifact directly (i.e. if it is present in the
<dependencies> section) then you cannot really modify that dependency.

You could try making use of the maven-dependency-plugin's unpack goal,
which is documented here:
http://maven.apache.org/plugins/maven-dependency-plugin/unpack-mojo.html

That would let you unpack the artifact somewhere temporary, exclude the
properties file, and perhaps then reassemble it.

Or, if you have control over the artifact you depend on, you could build
two artifacts: one without the properties file and one with it.  Then you
could depend on the one without the properties file.

Just a couple of ideas.

Best,
Laird

-- 
http://about.me/lairdnelson

Re: Properties file exlusion from dependency

Posted by Wayne Fay <wa...@gmail.com>.
> Is this possible? If so, how can I do it?

Please spell out what you are thinking for those of us who are unable
to interpret what you are asking about.

Wayne

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