From fe5a7105c49c29c3a922aaa9b69781c411321f8e Mon Sep 17 00:00:00 2001 From: Magnus Auvinen Date: Sat, 29 May 2010 15:20:18 +0000 Subject: [PATCH] fixed the automatic versioning --- scripts/cmd5.py | 8 +++++++- src/game/version.h | 4 +--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/scripts/cmd5.py b/scripts/cmd5.py index 85d3045bd..5eaab34aa 100644 --- a/scripts/cmd5.py +++ b/scripts/cmd5.py @@ -28,4 +28,10 @@ f = "" for filename in sys.argv[1:]: f += cstrip([l.strip() for l in file(filename)]) -print '#define GAME_NETVERSION_HASH "%s"' % hashlib.md5(f).hexdigest().lower()[16:] + +hash = hashlib.md5(f).hexdigest().lower()[16:] +# TODO: refactor hash that is equal to the 0.5 hash, remove when we +# TODO: remove when we don't need it any more +if hash == "7e33344691ca8a61": + hash = "b67d1f1a1eea234e" +print '#define GAME_NETVERSION_HASH "%s"' % hash diff --git a/src/game/version.h b/src/game/version.h index 0fe22c953..6505bf560 100644 --- a/src/game/version.h +++ b/src/game/version.h @@ -2,7 +2,5 @@ #define GAME_VERSION_H #include "generated/nethash.c" #define GAME_VERSION "trunk" -//#define GAME_NETVERSION "0.5 " GAME_NETVERSION_HASH -// TODO: hash forced during refactoring. Remove later on -#define GAME_NETVERSION "0.5 b67d1f1a1eea234e" +#define GAME_NETVERSION "0.5 " GAME_NETVERSION_HASH #endif