# HG changeset patch # User Santeri Piippo # Date 1387462085 -7200 # Node ID 74d71c6fdc20cc5157d49016f0089d72ab91789b # Parent 5a08d67ed7703eb4e907a8ddeb63e03c91db959a - non-release builds now display git revision info if available. This turned out to be much simpler to implement than I expected.. diff -r 5a08d67ed770 -r 74d71c6fdc20 ldforge.pro --- a/ldforge.pro Thu Dec 19 16:01:29 2013 +0200 +++ b/ldforge.pro Thu Dec 19 16:08:05 2013 +0200 @@ -32,6 +32,8 @@ OBJECTS_DIR = ./build_release/ } +exists(.git): DEFINES += GIT_DESCRIBE="\\\"$$system(git describe --tags)\\\"" + unix { LIBS += -lGLU } diff -r 5a08d67ed770 -r 74d71c6fdc20 src/main.cc --- a/src/main.cc Thu Dec 19 16:01:29 2013 +0200 +++ b/src/main.cc Thu Dec 19 16:08:05 2013 +0200 @@ -118,5 +118,10 @@ // ============================================================================= // ----------------------------------------------------------------------------- QString fullVersionString() -{ return "v" + versionString(); +{ +#if BUILD_ID != BUILD_RELEASE && defined (GIT_DESCRIBE) + return GIT_DESCRIBE; +#else + return "v" + versionString(); +#endif } \ No newline at end of file