From e16df2175045bcad3afb2034ae7fddcc7ffb8084 Mon Sep 17 00:00:00 2001 From: Till Hofmann Date: Wed, 10 Jul 2019 04:48:40 +0200 Subject: [PATCH 1/2] core: use competition year as major version Change the versioning scheme such that the major version is the competition year and the minor and micro versions can be used for bumps, e.g., for a bugfix after the release. --- src/libs/core/version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libs/core/version.h b/src/libs/core/version.h index 22b859dd0..8feb9afa7 100644 --- a/src/libs/core/version.h +++ b/src/libs/core/version.h @@ -24,8 +24,8 @@ #ifndef __CORE_VERSION_H_ #define __CORE_VERSION_H_ -#define FAWKES_VERSION_MAJOR 1 -#define FAWKES_VERSION_MINOR 1 +#define FAWKES_VERSION_MAJOR 2019 +#define FAWKES_VERSION_MINOR 0 #define FAWKES_VERSION_MICRO 0 #define FAWKES_VERSION_GT(major, minor) ((FAWKES_MAJOR_VERSION > major) || (FAWKES_MAJOR_VERSION == major) && (FAWKES_MINOR_VERSION > minor)) From 988428820b5ed3fa1637db9443b38a9f4bbbfff0 Mon Sep 17 00:00:00 2001 From: Till Hofmann Date: Wed, 10 Jul 2019 04:49:36 +0200 Subject: [PATCH 2/2] rcll: only display minor/micro version if != 0 By default, just use the major version as version string. Only put the minor or micro version into the string if they are not equal to 0. This allows us to have 'refbox 2019' while still allowing later version bumps. --- src/games/rcll/net.clp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/games/rcll/net.clp b/src/games/rcll/net.clp index 359fc8671..9b7a0f399 100644 --- a/src/games/rcll/net.clp +++ b/src/games/rcll/net.clp @@ -14,7 +14,11 @@ (pb-set-field ?vi "version_minor" ?*VERSION-MINOR*) (pb-set-field ?vi "version_micro" ?*VERSION-MICRO*) (pb-set-field ?vi "version_string" - (str-cat ?*VERSION-MAJOR* "." ?*VERSION-MINOR* "." ?*VERSION-MICRO*)) + (str-cat ?*VERSION-MAJOR* + (if (> ?*VERSION-MINOR* 0) then (str-cat "." ?*VERSION-MINOR*) else "") + (if (> ?*VERSION-MICRO* 0) then (str-cat "." ?*VERSION-MICRO*) else "") + ) + ) (return ?vi) )