Hi Robert,

thank you for your comment. The idea behind the property was that I also
give the BOM to my clients and they declare it as their parent. So now if
they want to use a newer version of the platform, all they have to do
is redeclare the property <platform.version> to be 1.2 or 1.5 or whatever
they want. Otherwise they will have to re-declare the whole dependency.

Now that I think about it I was wrong - if my clients want to update the
platform version all they have to do is update version of the parent BOM.

I still think though that this is a bug.


2016-05-03 16:17 GMT+02:00 Robert Patrick <[email protected]>:

> Why bother with the custom property?  Do this instead and the release
> plugin is happy:
>
> <groupId>com.mycompany</groupId>
> <artifactId>my-bom</artifactId>
> <version>1.0-SNAPSHOT</version>
>
> <dependencyManagement>
>    <dependencies>
>       <groupId>com.mycompany</groupId>
>       <artifactId>platform</artifactId>
>       <version>${project.version}</version>
>   </dependencies>
> </dependencyManagement>
>
>
>
> -----Original Message-----
> From: Petar Tahchiev [mailto:[email protected]]
> Sent: Tuesday, May 03, 2016 9:10 AM
> To: Maven Developers List
> Subject: Maven Release Plugin And A BOM
>
> Hi guys,
>
> I have a question regarding the release plugin. In my project I have a BOM
> in which I declare a property and a dependencyManagement section:
>
> <groupId>com.mycompany</groupId>
> <artifactId>my-bom</artifactId>
> <version>1.0-SNAPSHOT</version>
>
> <properties>
>     <platform.version>1.0-SNAPSHOT</platform.version>
> </properties>
>
> <dependencyManagement>
>    <dependencies>
>       <groupId>com.mycompany</groupId>
>       <artifactId>platform</artifactId>
>       <version>${platform.version}</version>
>   </dependencies>
> </dependencyManagement>
>
>
> and I also have 3 different projects that declare this BOM as their parent.
> All of these projects have the same version number (1.0-SNAPSHOT) and when
> I make a release I always release all of them. This is how it looks like:
> 1) I change platform.version property to 1.0, commit, push and release the
> bom.
> 2) I try to release first of my other projects and now the release plugin
> is asking me to resolve the version of the BOM. Ok, fair enough, I resolve
> it to 1.0 but then it asks me again to resolve the version of
> com.mycompany:platform. This clearly is a bug right? I have changed it to
> 1.0 before so it is no longer a SNAPSHOT???
> If you think this is a problem, I will submit it in the JIRA and try to
> fix it. I'm just not sure if it's a bug or maybe it's a known issue, or
> maybe that's how it is supposed to be.
>
> --
> Regards, Petar!
> Karlovo, Bulgaria.
> ---
> Public PGP Key at:
> http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x19658550C3110611
> Key Fingerprint: A369 A7EE 61BC 93A3 CDFF  55A5 1965 8550 C311 0611
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>


-- 
Regards, Petar!
Karlovo, Bulgaria.
---
Public PGP Key at:
http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x19658550C3110611
Key Fingerprint: A369 A7EE 61BC 93A3 CDFF  55A5 1965 8550 C311 0611

Reply via email to