maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anders Hammar <and...@hammar.net>
Subject Re: Maven 3.0.4 and maven-release-plugin 2.3.2
Date Fri, 09 Nov 2012 20:27:21 GMT
I don't have the in-depth knowledge of the release-plugin, but I think that
the problem might be that you don't have an aggregate build. So the
dependency to commons in bizcore is actually referencing a SNAPSHOT version
(the value of project.version). I would even go as far as if you don't have
a multi-module build (an aggregating build), using the current project
version number in the GAV of a dependency is weird.

/Anders


On Fri, Nov 9, 2012 at 4:19 PM, S I <srexi@hotmail.com> wrote:

>     I've recently upgraded to maven 3.0.4.  Things went smoothly, but to
> complete the upgrade I wanted to see how my release process worked on top
> of the latest maven edition.
>     I've run into some problems, and I'm in need of some advice.  I'm
> using maven 3.0.4 with maven-release-plugin 2.3.2.
>     My release process uses the maven release plugin in batch mode.  I
> supply command line arguments concerning the tag version and the next
> snapshot version.  I start the release with my base module (the project
> that all others depend on 'commons').  That release works great, scm is
> handled as expected.  When I move on to the next project ('bizcore')
> that is to be released, its dependency on 'commons' has become an issue.
> The second phase of release:prepare checks to make sure that there are no
> SNAPSHOT dependencies. The way I've referenced the dependency to 'commons'
> in 'bizcore' looks like this:
>
>     <dependency>
>         <groupId>com.mybiz</groupId>
>         <artifactId>commons</artifactId>
>         <version>${project.version}</version>
>     </dependency>
>
>     The expression ${project.version} is a change I made due to the upgrade
> to maven 3x.  It used to say ${version} (referecing the projet <version/>
> element), which I was warned about the first time I built the project.
> Maven suggested I make the above change so I complied.  I understand that
> ${project.version} property is going to eveluate to the current project
> version, which for 'bizcore' at the time of release is a SNAPSHOT version.
> This is where 'release:prepare' fails with:
>
> 'Can't release project due to non released dependencies'
>
>     This makes sense to me.  I understand why it's failing, but I'm not
> sure what I need to do to convince the release plugin to bump up the
> dependency version to the latest tag version of 'commons'.
>
>     I have been looking at the versions plugin, but that would suggest
> that I release my first project with the release plugin, move on to the
> next project where I would run the versions plugin to update dependencies,
> check those changes into SCM and then start to release my second project.
>
>     Is that the way I need to release now?  With maven 2.2.1 I could just
> roll through my projects with the release plugin in the correct order
> to release my project suite.  I feel like I'm missing something obvious,
> because I don't think that maven would change a process to involve another
> plugin.  Any advice would be appreciated.
>
> Thank you,
> srexi
>

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