You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Rémy <re...@gmail.com> on 2008/10/28 00:25:43 UTC

maven-release-plugin

I use the maven-release-plugin, the two goals prepare and perform. But I
don't want Maven generate the pom for the next iteration how can I do that ?
I want simply to pass from the snapshots to the releases.
Thanks.
Rémy.
-- 
View this message in context: http://www.nabble.com/maven-release-plugin-tp20198588p20198588.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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


Re: maven-release-plugin

Posted by Kalle Korhonen <ka...@gmail.com>.
If the submodules don't change, you just disconnect them from the main
build, change the parent to point to a released version and release
separately. The plugin won't change the versions if they are not part of the
build. All poms in the trunk or branches should use snapshot versions so
they are ready for development and release whenever you decide to do so. If
you use release versions in the poms, what *will* happen is that somebody
makes edits to that module and confusion arises because other people don't
see those changes since the build won't pick up changes because the version
hasn't changed.

Kalle


On Tue, Oct 28, 2008 at 3:19 AM, Rémy <re...@gmail.com> wrote:

>
> Hi,
> Thanks for your responses. I understand the idea.
> Here are my worries (I'll try to be clear).
> I've got a multi-module project. A parent POM and childs (25). The first
> time all the pom are in snapshot version. When I use the release:prepare
> plugin, it create a snapshot pom for the parent and all the childs for the
> next iteration. But some modules don't change for month and the plugin
> increments unnecessarily the version at every release.
> I prefer that developers change (create a snapshot version) the pom
> themselves.
> Thanks.
> Rémy.
>
>
> craigb wrote:
> >
> > Hi Rémy,
> >
> > I don't have an answer for you, but I just wanted to make a couple of
> > points.
> >
> > * you only run the release plugin on a snapshot version
> > * normally, a snapshot will be on the trunk or a branch
> > * release:prepare creates a tag with the non-snapshot version, which
> > is the "released code"
> > * if you then had the situation where you *didn't* move the version
> > numbers on, you would have a non-snapshot version on the trunk or a
> > branch.
> >
> > This scenario makes it possible to have multiple builds of the same
> > version number with different code in it. If these were deployed to a
> > shared maven repository, there is no indication which one you are
> > looking at.
> >
> > Having snapshot in the version makes it very clear that it is in a
> > transient state, and not released code.
> >
> > Maybe if you explain why you want to do this, I can be of more help.
> >
> > cheers,
> > Craig
> >
> > On Tue, Oct 28, 2008 at 10:25 AM, Rémy <re...@gmail.com>
> wrote:
> >>
> >> I use the maven-release-plugin, the two goals prepare and perform. But I
> >> don't want Maven generate the pom for the next iteration how can I do
> >> that ?
> >> I want simply to pass from the snapshots to the releases.
> >> Thanks.
> >> Rémy.
> >> --
> >> View this message in context:
> >> http://www.nabble.com/maven-release-plugin-tp20198588p20198588.html
> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: users-help@maven.apache.org
> >>
> >>
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
> >
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/maven-release-plugin-tp20198588p20204508.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: maven-release-plugin

Posted by Rémy <re...@gmail.com>.
Hi,
Thanks for your responses. I understand the idea. 
Here are my worries (I'll try to be clear).
I've got a multi-module project. A parent POM and childs (25). The first
time all the pom are in snapshot version. When I use the release:prepare
plugin, it create a snapshot pom for the parent and all the childs for the
next iteration. But some modules don't change for month and the plugin
increments unnecessarily the version at every release.
I prefer that developers change (create a snapshot version) the pom
themselves.
Thanks.
Rémy.


craigb wrote:
> 
> Hi Rémy,
> 
> I don't have an answer for you, but I just wanted to make a couple of
> points.
> 
> * you only run the release plugin on a snapshot version
> * normally, a snapshot will be on the trunk or a branch
> * release:prepare creates a tag with the non-snapshot version, which
> is the "released code"
> * if you then had the situation where you *didn't* move the version
> numbers on, you would have a non-snapshot version on the trunk or a
> branch.
> 
> This scenario makes it possible to have multiple builds of the same
> version number with different code in it. If these were deployed to a
> shared maven repository, there is no indication which one you are
> looking at.
> 
> Having snapshot in the version makes it very clear that it is in a
> transient state, and not released code.
> 
> Maybe if you explain why you want to do this, I can be of more help.
> 
> cheers,
> Craig
> 
> On Tue, Oct 28, 2008 at 10:25 AM, Rémy <re...@gmail.com> wrote:
>>
>> I use the maven-release-plugin, the two goals prepare and perform. But I
>> don't want Maven generate the pom for the next iteration how can I do
>> that ?
>> I want simply to pass from the snapshots to the releases.
>> Thanks.
>> Rémy.
>> --
>> View this message in context:
>> http://www.nabble.com/maven-release-plugin-tp20198588p20198588.html
>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/maven-release-plugin-tp20198588p20204508.html
Sent from the Maven - Users mailing list archive at Nabble.com.


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


Re: maven-release-plugin

Posted by John Stoneham <ly...@lyrically.net>.
 >> I use the maven-release-plugin, the two goals prepare and perform.
 >> But I don't want Maven generate the pom for the next iteration how
 >> can I do that ? I want simply to pass from the snapshots to the
 >> releases.

Take note of Craig's excellent points. The idea is for the release 
plugin to do everything necessary for your next release, which involves 
moving the POM up to a snapshot focusing on the next release. In the 
process it creates you a tag with release version numbers; release files 
should be considered immutable anyway (updating them requires a new 
version number).

If you need the files with the release version number, they are 
available on the tag - just copy from the tag, if for example you want 
to branch from there (mvn release:branch also works quite nicely for 
this but is not required).

If you want Maven to set the version numbers back the way they were 
before the release, just type in the existing SNAPSHOT version numbers 
when Maven asks you for the next development version. I do this when 
releasing from a branch so that the branch remains consistent with the 
version it was planned for. New changes go on another branch.

- John


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


Re: maven-release-plugin

Posted by Craig <su...@gmail.com>.
Hi Rémy,

I don't have an answer for you, but I just wanted to make a couple of points.

* you only run the release plugin on a snapshot version
* normally, a snapshot will be on the trunk or a branch
* release:prepare creates a tag with the non-snapshot version, which
is the "released code"
* if you then had the situation where you *didn't* move the version
numbers on, you would have a non-snapshot version on the trunk or a
branch.

This scenario makes it possible to have multiple builds of the same
version number with different code in it. If these were deployed to a
shared maven repository, there is no indication which one you are
looking at.

Having snapshot in the version makes it very clear that it is in a
transient state, and not released code.

Maybe if you explain why you want to do this, I can be of more help.

cheers,
Craig

On Tue, Oct 28, 2008 at 10:25 AM, Rémy <re...@gmail.com> wrote:
>
> I use the maven-release-plugin, the two goals prepare and perform. But I
> don't want Maven generate the pom for the next iteration how can I do that ?
> I want simply to pass from the snapshots to the releases.
> Thanks.
> Rémy.
> --
> View this message in context: http://www.nabble.com/maven-release-plugin-tp20198588p20198588.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

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