You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by el...@apache.org on 2020/01/02 12:36:59 UTC

[maven-site] 01/01: [MNGSITE-387] Mention semantic versioning

This is an automated email from the ASF dual-hosted git repository.

elharo pushed a commit to branch elharo-patch-5
in repository https://gitbox.apache.org/repos/asf/maven-site.git

commit cbb5e0efb87ab8fc8a91f432c8de1c1ae1e86d77
Author: Elliotte Rusty Harold <el...@users.noreply.github.com>
AuthorDate: Thu Jan 2 07:36:49 2020 -0500

    [MNGSITE-387] Mention semantic versioning
    
    @rfscholte @hboutemy This seems like a straightforward description that covers most common use cases. Unfortunately i'm not sure it's true, especially when plus signs (build identifiers) are considered. Posting for discussion.
---
 content/apt/pom.apt | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/content/apt/pom.apt b/content/apt/pom.apt
index 06dd045..cbb349c 100644
--- a/content/apt/pom.apt
+++ b/content/apt/pom.apt
@@ -457,6 +457,14 @@ mvn install:install-file -Dfile=non-maven-proj.jar -DgroupId=some.group -Dartifa
 
 *** {Version Order Specification}:
 
+  If version strings are syntactically correct [Semantic Versioning 2.0.0](https://semver.org/spec/v2.0.0.html),
+  version numbers, then version comparison follows the precedence rules outlined in that specification.
+  These versions are ASCII alphanumeric strings such as 2.15.2-alpha commonly encountered.
+  More precisely, this is true if both version numbers to be compared match the "valid semver"
+  production in the BNF grammar in the semantic versioning specification.
+  It does not consider any semantics implied by that specification.
+
+  When version strings do not follow semantic versioning, a more complex set of rule is required. 
   The Maven coordinate is split in tokens between dots ('<<<.>>>'), hyphens ('<<<->>>') and transitions between digits and characters.
   The separator is recorded and will have effect on the order. A transition 
   between digits and characters is equivalent to a hyphen.