You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Steve Francolla <sf...@gmail.com> on 2010/03/27 01:05:44 UTC

How to manipulate pom produced for release before deployment to Nexus?

Hi. I've automated my deployment to Nexus OSS repo with
maven-release-plugin.  My project has open source dependencies that do not
source from Central.  So, since Nexus requires projects to be
self-contained, I'm also using maven-shade-plugin to include those
dependencies in the jar and strip their <dependency/> tags from the
release's pom.xml.  However, the <repositories/> block still exists in it,
this makes the package not self-contained, and therefore it fails to release
on Nexus.  To solve the problem, I need a way to strip the <repositories/>
branch of xml from the release pom.xml.

Is there a plug-in out there that would help me do this?
Do I need to write something custom?

Thanks.


Steven

Re: How to manipulate pom produced for release before deployment to Nexus?

Posted by Wendy Smoak <ws...@gmail.com>.
On Fri, Mar 26, 2010 at 8:05 PM, Steve Francolla <sf...@gmail.com> wrote:
> Hi. I've automated my deployment to Nexus OSS repo with
> maven-release-plugin.  My project has open source dependencies that do not
> source from Central.  So, since Nexus requires projects to be
> self-contained, I'm also using maven-shade-plugin to include those
> dependencies in the jar and strip their <dependency/> tags from the
> release's pom.xml.  However, the <repositories/> block still exists in it,
> this makes the package not self-contained, and therefore it fails to release
> on Nexus.  To solve the problem, I need a way to strip the <repositories/>
> branch of xml from the release pom.xml.

The pom in the repo ought to match the tag, so changing it after the
release seems wrong.

How about putting those repositories in your settings.xml instead of in the pom?

Or... (I'd have to check the model) can you put repositories inside a profile?

Otherwise, I'd probably just comment out the repositories right before
the release, and un-comment them after.

-- 
Wendy

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