You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Graham Leggett <mi...@sharp.fm> on 2007/06/06 13:41:50 UTC

Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

On Tue, June 5, 2007 9:06 pm, Brett Porter wrote:

> Right. The reason for not choosing to install by default is that you
> end up with a "release" in your local repository which is not the
> final one.

We've run into this problem as well - the version being tested, as far as
I am aware, is the SNAPSHOT version, meaning that at the end of this, an
up to date build of snapshot will be included in the local repository,
which is perfectly reasonable.

The workaround for us to release aggregated projects is like this:

mvn install release:prepare

Regards,
Graham
--



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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Graham Leggett <mi...@sharp.fm>.
On Wed, June 6, 2007 5:25 pm, Mark Donszelmann wrote:

> well, as far as I can conclude, an aggregated build will calculate
> the order in which to generate (and install) the artifacts, so that
> any module dependent on them is run later than the one generating
> them.

That won't matter. If you don't run the install step, then artifact A,
required by artifact B, won't be available to artifact B even though you
built (but didn't install) A - and your build of artifact B will fail.

If the build does succeed, it will be by accident - you'll be relying on
some previous invocation of mvn install that build artifact A.

> I am still confused though about your command:
>
> mvn install release:prepare
>
> will just execute these in order, so the poms would not have
> been changed.
>
> Max suggests to use -DpreparationalGoals="clean install"
> which would change the goals as part of the release:prepare.

I will try that the next time we do a release, which should be in the next
day or two.

Regards,
Graham
--



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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Mark Donszelmann <Ma...@slac.stanford.edu>.
Hi

well, as far as I can conclude, an aggregated build will calculate
the order in which to generate (and install) the artifacts, so that
any module dependent on them is run later than the one generating
them.

I am still confused though about your command:

mvn install release:prepare

will just execute these in order, so the poms would not have
been changed.

Max suggests to use -DpreparationalGoals="clean install"
which would change the goals as part of the release:prepare.

Regards
Mark

On Jun 6, 2007, at 8:12 AM, Graham Leggett wrote:

> On Wed, June 6, 2007 4:50 pm, Mark Donszelmann wrote:
>
>>> The workaround for us to release aggregated projects is like this:
>>>
>>> mvn install release:prepare
>>>
>> but this would do the install w/o the poms being changed from 3.3-
>> SNAPSHOT to 3.3,
>> so this would not help.
>
> And yet it does help.
>
> I suspect that in "aggregated mode" the versions are not changed,  
> but the
> install is not done, it only goes as far as "integration-test". If the
> versions were changed to 3.3 before running the aggregated build, the
> aggregated build would always fail due to missing artifacts, and this
> doesn't happen in practise.
>
> Regards,
> Graham
> --
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>


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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Graham Leggett <mi...@sharp.fm>.
On Wed, June 6, 2007 4:50 pm, Mark Donszelmann wrote:

>> The workaround for us to release aggregated projects is like this:
>>
>> mvn install release:prepare
>>
> but this would do the install w/o the poms being changed from 3.3-
> SNAPSHOT to 3.3,
> so this would not help.

And yet it does help.

I suspect that in "aggregated mode" the versions are not changed, but the
install is not done, it only goes as far as "integration-test". If the
versions were changed to 3.3 before running the aggregated build, the
aggregated build would always fail due to missing artifacts, and this
doesn't happen in practise.

Regards,
Graham
--



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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Emmanuel Venisse <em...@venisse.net>.

Graham Leggett a écrit :
> On Fri, June 8, 2007 1:57 pm, Emmanuel Venisse wrote:
> 
>> If you want to install artifacts in your local repo during the prepare
>> process and don't want to use 'clean verify' goals, you can configure
>> preparationGoals parameter on the prepare mojo
>> (http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html)
> 
> This remains a workaround though.
> 
> Without this step, it is not possible to run release:prepare on an
> aggregated project and expect it to always work.
> 
'clean verify' works fine in the majority of case but can't work if a dependency (that is a module in the reactor) is used in a plugin like the dependency plugin because this plugin try to download 
the dep that doesn't exist yet in the repo. It's the same result if you run 'mvn clean package' on your project with an empty local repo.

Emmanuel


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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Graham Leggett <mi...@sharp.fm>.
On Fri, June 8, 2007 1:57 pm, Emmanuel Venisse wrote:

> If you want to install artifacts in your local repo during the prepare
> process and don't want to use 'clean verify' goals, you can configure
> preparationGoals parameter on the prepare mojo
> (http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html)

This remains a workaround though.

Without this step, it is not possible to run release:prepare on an
aggregated project and expect it to always work.

Regards,
Graham
--



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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Emmanuel Venisse <em...@venisse.net>.

Mark Donszelmann a écrit :
> Hi
> 
> On Jun 6, 2007, at 4:41 AM, Graham Leggett wrote:
> 
>> On Tue, June 5, 2007 9:06 pm, Brett Porter wrote:
>>
>>> Right. The reason for not choosing to install by default is that you
>>> end up with a "release" in your local repository which is not the
>>> final one.
>>
>> We've run into this problem as well - the version being tested, as far as
>> I am aware, is the SNAPSHOT version, meaning that at the end of this, an
>> up to date build of snapshot will be included in the local repository,
>> which is perfectly reasonable.
>>
>> The workaround for us to release aggregated projects is like this:
>>
>> mvn install release:prepare
>>
> but this would do the install w/o the poms being changed from 
> 3.3-SNAPSHOT to 3.3,
> so this would not help.

If you want to install artifacts in your local repo during the prepare process and don't want to use 'clean verify' goals, you can configure preparationGoals parameter on the prepare mojo 
(http://maven.apache.org/plugins/maven-release-plugin/prepare-mojo.html)

Emmanuel



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


Re: Maven Release Plugin seems to run "clean verify" and miss out on install for aggregate projects

Posted by Mark Donszelmann <Ma...@slac.stanford.edu>.
Hi

On Jun 6, 2007, at 4:41 AM, Graham Leggett wrote:

> On Tue, June 5, 2007 9:06 pm, Brett Porter wrote:
>
>> Right. The reason for not choosing to install by default is that you
>> end up with a "release" in your local repository which is not the
>> final one.
>
> We've run into this problem as well - the version being tested, as  
> far as
> I am aware, is the SNAPSHOT version, meaning that at the end of  
> this, an
> up to date build of snapshot will be included in the local repository,
> which is perfectly reasonable.
>
> The workaround for us to release aggregated projects is like this:
>
> mvn install release:prepare
>
but this would do the install w/o the poms being changed from 3.3- 
SNAPSHOT to 3.3,
so this would not help.

Regards
Mark



> Regards,
> Graham
> --
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>


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