maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Hervé BOUTEMY <herve.bout...@free.fr>
Subject Re: How to use 5 digit version numbers with Maven ?
Date Sat, 09 Jan 2016 16:37:24 GMT
in fact, the way the issue is described is misleading:
"How to use 5 digit version numbers with Maven ?" and
"Maven only handles 3 digit version numbers using the versions-maven-plugin"

it should be phrased:
"How to use 5 digit version numbers with versions-maven-plugin?" and
"versions-maven-plugin only handles 3 digit version numbers"


because Maven itself has no limitation on digits: like Karl Heinz pointed out, 
there was a limitation in Maven 2, but it was removed in Maven 3 with 
https://cwiki.apache.org/confluence/display/MAVENOLD/Versioning


and FYI, Maven itself does only comparison on versions, no updates

Plugins can do a lot of different things, and multiple plugins propose to 
update version: the most known being maven-release-plugin (from Apache Maven 
team) and versions-maven-plugin (from MojoHaus team)


Regards,

Hervé
(who worked hard a few yeas ago on removing the limitation in Maven 3 :) )

Le jeudi 7 janvier 2016 20:16:44 Karl Heinz Marbaise a écrit :
> Hi,
> 
> On 1/7/16 1:08 PM, Mehul Sanghvi wrote:
> > We need to use 5 digit version numbers going forward.  Maven only handles
> > 3
> > digit version numbers
> 
> where is this documented ?
> 
> which is simply not true.....
> 
> https://cwiki.apache.org/confluence/display/MAVENOLD/Versioning
> 
> Since Maven 3 you can use as many version numbers as you like...
> 
> > using the versions-maven-plugin.  Is there a way to use 5 digits for
> > project.version ?
> > 
> > What we want to do is use 1.2.3.4.5-SNAPSHOT vs 1.2.3-SNAPSHOT and
> > 1.2.3.4.5 vs 1.2.3 after
> > the release.
> 
> You should simply use it....cause it works...
> 
> 
> Furthermore if you use Maven 3.2.5+ you can check the behaviour on
> command line via: (You have to change the maven-artifact-VERSION.jar
> accordingly to your Maven installation) this small CLI app which is
> included in your maven distribution:
> 
> ~$ java -jar /usr/share/maven/lib/maven-artifact-3.2.5.jar
> 1.0.2.5-SNAPSHOT 1.0.2.6-SNAPSHOT
> Display parameters as parsed by Maven (in canonical form) and comparison
> result:
> 1. 1.0.2.5-SNAPSHOT == 1.0.2.5-snapshot
>     1.0.2.5-SNAPSHOT < 1.0.2.6-SNAPSHOT
> 2. 1.0.2.6-SNAPSHOT == 1.0.2.6-snapshot
> ~$ java -jar /usr/share/maven/lib/maven-artifact-3.2.5.jar
> 1.0.2.5.0.0-SNAPSHOT 1.0.2.6.0.0-SNAPSHOT
> Display parameters as parsed by Maven (in canonical form) and comparison
> result:
> 1. 1.0.2.5.0.0-SNAPSHOT == 1.0.2.5-snapshot
>     1.0.2.5.0.0-SNAPSHOT < 1.0.2.6.0.0-SNAPSHOT
> 2. 1.0.2.6.0.0-SNAPSHOT == 1.0.2.6-snapshot
> ~$ java -jar /usr/share/maven/lib/maven-artifact-3.2.5.jar
> 1.0.2.5.10.0-SNAPSHOT 1.0.2.6.0.0-SNAPSHOT
> Display parameters as parsed by Maven (in canonical form) and comparison
> result:
> 1. 1.0.2.5.10.0-SNAPSHOT == 1.0.2.5.10-snapshot
>     1.0.2.5.10.0-SNAPSHOT < 1.0.2.6.0.0-SNAPSHOT
> 2. 1.0.2.6.0.0-SNAPSHOT == 1.0.2.6-snapshot
> ~$ java -jar /usr/share/maven/lib/maven-artifact-3.2.5.jar
> 1.0.2.5.100.0-SNAPSHOT 1.0.2.6.0.0-SNAPSHOT
> Display parameters as parsed by Maven (in canonical form) and comparison
> result:
> 1. 1.0.2.5.100.0-SNAPSHOT == 1.0.2.5.100-snapshot
>     1.0.2.5.100.0-SNAPSHOT < 1.0.2.6.0.0-SNAPSHOT
> 2. 1.0.2.6.0.0-SNAPSHOT == 1.0.2.6-snapshot
> 
> 
> Kind regards
> Karl Heinz Marbaise
> 
> ---------------------------------------------------------------------
> 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


Mime
View raw message