1
0
mirror of https://github.com/alliedmodders/metamod-source.git synced 2024-11-28 10:24:20 +01:00

Add rev count back.

This commit is contained in:
David Anderson 2014-05-25 03:26:08 -07:00
parent 149bc768b7
commit 1817478b0e
4 changed files with 11 additions and 6 deletions

View File

@ -70,7 +70,8 @@ bool Command_Meta(IMetamodSourceCommandInfo *info)
else if (strcmp(command, "version") == 0) else if (strcmp(command, "version") == 0)
{ {
CONMSG("Metamod:Source version %s\n", METAMOD_VERSION); CONMSG("Metamod:Source version %s\n", METAMOD_VERSION);
CONMSG("Build ID: %s\n", METAMOD_BUILD_ID); CONMSG("Built from: https://github.com/alliedmodders/metamod-source/commit/%s\n", METAMOD_BUILD_SHA);
CONMSG("Build ID: %s:%s\n", METAMOD_BUILD_LOCAL_REV, METAMOD_BUILD_SHA);
if (g_Metamod.IsLoadedAsGameDLL()) if (g_Metamod.IsLoadedAsGameDLL())
{ {

View File

@ -64,13 +64,15 @@ def output_version_header():
#define _METAMOD_AUTO_VERSION_INFORMATION_H_ #define _METAMOD_AUTO_VERSION_INFORMATION_H_
#define MMS_BUILD_STRING \"{0}\" #define MMS_BUILD_STRING \"{0}\"
#define MMS_BUILD_UNIQUEID \"{1}\" MMS_BUILD_STRING #define MMS_BUILD_LOCAL_REV \"{5}\"
#define MMS_BUILD_SHA \"{1}\"
#define MMS_BUILD_UNIQUEID \"{5}:{1}\" MMS_BUILD_STRING
#define MMS_FULL_VERSION \"{2}.{3}.{4}\" MMS_BUILD_STRING #define MMS_FULL_VERSION \"{2}.{3}.{4}\" MMS_BUILD_STRING
#define MMS_FILE_VERSION {5},{6},{7},0 #define MMS_FILE_VERSION {2},{3},{4},0
#endif /* _METAMOD_AUTO_VERSION_INFORMATION_H_ */ #endif /* _METAMOD_AUTO_VERSION_INFORMATION_H_ */
""".format(tag, shorthash, major, minor, release, major, minor, release)) """.format(tag, shorthash, major, minor, release, count))
output_version_header() output_version_header()

View File

@ -26,6 +26,7 @@
#include <metamod_version.h> #include <metamod_version.h>
#include <versionlib.h> #include <versionlib.h>
const char *METAMOD_BUILD_ID = MMS_BUILD_UNIQUEID; const char *METAMOD_BUILD_LOCAL_REV = MMS_BUILD_LOCAL_REV;
const char *METAMOD_BUILD_SHA = MMS_BUILD_SHA;
const char *METAMOD_VERSION = MMS_FULL_VERSION; const char *METAMOD_VERSION = MMS_FULL_VERSION;

View File

@ -25,7 +25,8 @@
#ifndef _INCLUDE_METAMOD_VERSIONLIB_H_ #ifndef _INCLUDE_METAMOD_VERSIONLIB_H_
#define _INCLUDE_METAMOD_VERSIONLIB_H_ #define _INCLUDE_METAMOD_VERSIONLIB_H_
extern "C" const char *METAMOD_BUILD_ID; extern "C" const char *METAMOD_BUILD_LOCAL_REV;
extern "C" const char *METAMOD_BUILD_SHA;
extern "C" const char *METAMOD_VERSION; extern "C" const char *METAMOD_VERSION;
#endif // _INCLUDE_METAMOD_VERSIONLIB_H_ #endif // _INCLUDE_METAMOD_VERSIONLIB_H_