From 0454f9578c206b882ab871c55373327515e22cda Mon Sep 17 00:00:00 2001 From: Tom Scanlan Date: Fri, 15 Sep 2023 19:17:50 -0400 Subject: [PATCH] doc: clarify caret requirements --- src/doc/src/reference/specifying-dependencies.md | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/doc/src/reference/specifying-dependencies.md b/src/doc/src/reference/specifying-dependencies.md index a91f14f25f5..746b5fcb25a 100644 --- a/src/doc/src/reference/specifying-dependencies.md +++ b/src/doc/src/reference/specifying-dependencies.md @@ -57,8 +57,17 @@ using special operators, though it shouldn't be necessary most of the time. ### Caret requirements -**Caret requirements** are an alternative syntax for the default strategy, -`^1.2.3` is exactly equivalent to `1.2.3`. +**Caret requirements** are the default version requirement strategy. +This version strategy allows [SemVer] compatible updates. +They are specified as version requirements with a leading caret (`^`). + +`^1.2.3` is an example of a caret requirement. + +Leaving off the caret is a simplified equivalent syntax to using caret requirements. +While caret requirements are the default, it is recommended to use the +simplified syntax when possible. + +`log = "^1.2.3"` is exactly equivalent to `log = "1.2.3"`. ### Tilde requirements