From 8b29cbf6e82eac0d015aed6fc288ff2f052cf8a2 Mon Sep 17 00:00:00 2001 From: Lzu Tao Date: Sun, 5 May 2019 21:12:31 +0700 Subject: [PATCH] doc: Format examples of version to ease reading --- .../src/reference/specifying-dependencies.md | 26 +++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/src/doc/src/reference/specifying-dependencies.md b/src/doc/src/reference/specifying-dependencies.md index c25a7416267..ca6652889d2 100644 --- a/src/doc/src/reference/specifying-dependencies.md +++ b/src/doc/src/reference/specifying-dependencies.md @@ -40,14 +40,14 @@ Here are some more examples of caret requirements and the versions that would be allowed with them: ```notrust -^1.2.3 := >=1.2.3 <2.0.0 -^1.2 := >=1.2.0 <2.0.0 -^1 := >=1.0.0 <2.0.0 -^0.2.3 := >=0.2.3 <0.3.0 -^0.2 := >= 0.2.0 < 0.3.0 -^0.0.3 := >=0.0.3 <0.0.4 -^0.0 := >=0.0.0 <0.1.0 -^0 := >=0.0.0 <1.0.0 +^1.2.3 := >=1.2.3 <2.0.0 +^1.2 := >=1.2.0 <2.0.0 +^1 := >=1.0.0 <2.0.0 +^0.2.3 := >=0.2.3 <0.3.0 +^0.2 := >=0.2.0 <0.3.0 +^0.0.3 := >=0.0.3 <0.0.4 +^0.0 := >=0.0.0 <0.1.0 +^0 := >=0.0.0 <1.0.0 ``` This compatibility convention is different from SemVer in the way it treats @@ -65,9 +65,9 @@ version, then minor- and patch-level changes are allowed. `~1.2.3` is an example of a tilde requirement. ```notrust -~1.2.3 := >=1.2.3 <1.3.0 -~1.2 := >=1.2.0 <1.3.0 -~1 := >=1.0.0 <2.0.0 +~1.2.3 := >=1.2.3 <1.3.0 +~1.2 := >=1.2.0 <1.3.0 +~1 := >=1.0.0 <2.0.0 ``` ### Wildcard requirements @@ -78,8 +78,8 @@ positioned. `*`, `1.*` and `1.2.*` are examples of wildcard requirements. ```notrust -* := >=0.0.0 -1.* := >=1.0.0 <2.0.0 +* := >=0.0.0 +1.* := >=1.0.0 <2.0.0 1.2.* := >=1.2.0 <1.3.0 ```