aboutsummaryrefslogtreecommitdiffstats
path: root/share
diff options
context:
space:
mode:
authorMike McQuaid2016-08-18 12:51:39 +0100
committerMike McQuaid2016-08-18 15:04:51 +0100
commitcc2a90ec8d4dc8b26a7658f4424cf6949d0bf4cb (patch)
tree5e00af885910da7829c3413bbe0afec0128eb619 /share
parentb39eba6c5f0f6f1b19e663df52bc72b9d8518886 (diff)
downloadbrew-cc2a90ec8d4dc8b26a7658f4424cf6949d0bf4cb.tar.bz2
Formula-Cookbook: add version_scheme documentation.
Diffstat (limited to 'share')
-rw-r--r--share/doc/homebrew/Formula-Cookbook.md6
1 files changed, 6 insertions, 0 deletions
diff --git a/share/doc/homebrew/Formula-Cookbook.md b/share/doc/homebrew/Formula-Cookbook.md
index ab51d431e..1772fbd4f 100644
--- a/share/doc/homebrew/Formula-Cookbook.md
+++ b/share/doc/homebrew/Formula-Cookbook.md
@@ -193,6 +193,12 @@ Where a dependent of a formula fails against a new version of that dependency it
[`revision`](http://www.rubydoc.info/github/Homebrew/brew/master/Formula#revision%3D-class_method)s are also used for formulae that move from the system OpenSSL to the Homebrew-shipped OpenSSL without any other changes to that formula. This ensures users aren’t left exposed to the potential security issues of the outdated OpenSSL. An example of this can be seen in [this commit](https://github.com/Homebrew/homebrew/commit/6b9d60d474d72b1848304297d91adc6120ea6f96).
+## Version Scheme Changes
+
+Sometimes formulae have version schemes that change such that a direct comparison between two versions no longer produces the correct result. For example, a project might be version `13` and then decide to become `1.0.0`. As `13` is translated to `13.0.0` by our versioning system by default this requires intervention.
+
+Where a version scheme of a formula fails to recognise a new version as newer it must receive a [`version_scheme`](http://www.rubydoc.info/github/Homebrew/brew/master/Formula#version_scheme%3D-class_method). An example of this can be seen [here](https://github.com/Homebrew/homebrew-core/pull/4006).
+
## Double-check for dependencies
When you already have a lot of formulae installed, it's easy to miss a common dependency. You can double-check which libraries a binary links to with the `otool` command (perhaps you need to use `xcrun otool`):