Commit b78d0757 authored by Jose A. Lopes's avatar Jose A. Lopes
Browse files

Add 'buildVersion' for calculating Ganeti versions



Add 'buildVersion' which calculates Ganeti versions and it is the
Haskell counterpart of 'BuildVersion' in 'lib/constants.py'.
Signed-off-by: default avatarJose A. Lopes <jabolopes@google.com>
Reviewed-by: default avatarThomas Thrainer <thomasth@google.com>
parent fd653cbd
......@@ -101,3 +101,9 @@ priorityNormal = 0
priorityHigh :: Int
priorityHigh = -10
-- | Calculates int version number from major, minor and revision
-- numbers.
buildVersion :: Int -> Int -> Int -> Int
buildVersion major minor revision =
1000000 * major + 10000 * minor + 1 * revision
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment