From 897bd3eb6961fd1576313a043ef32dbb700286f1 Mon Sep 17 00:00:00 2001 From: TK3 Date: Thu, 28 Mar 2013 15:59:04 -0400 Subject: [PATCH] gitrev.bat revision marking for server 2.1 --- common/common.vcxproj | 8 ++++---- common/env.cpp | 2 +- gitrev.bat | 9 +++++++++ shell/shell.rc | Bin 4790 -> 4682 bytes version.tmpl | 1 - 5 files changed, 14 insertions(+), 6 deletions(-) create mode 100644 gitrev.bat diff --git a/common/common.vcxproj b/common/common.vcxproj index 46b96cc09..0a283960a 100644 --- a/common/common.vcxproj +++ b/common/common.vcxproj @@ -81,7 +81,7 @@ true - "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir).\version.tmpl" "$(SolutionDir).\version.h" + "$(SolutionDir).\gitrev.bat" @@ -116,7 +116,7 @@ true - "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir).\version.tmpl" "$(SolutionDir).\version.h" + "$(SolutionDir).\gitrev.bat" false @@ -131,7 +131,7 @@ "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir)\version.tmpl" "$(SolutionDir)\version.h" - "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir).\version.tmpl" "$(SolutionDir).\version.h" + "$(SolutionDir).\gitrev.bat" compiler/vs/disable_silly_warnings.h @@ -142,7 +142,7 @@ "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir)\version.tmpl" "$(SolutionDir)\version.h" - "SubWCRev.exe" "$(SolutionDir)." "$(SolutionDir).\version.tmpl" "$(SolutionDir).\version.h" + "$(SolutionDir).\gitrev.bat" compiler/vs/disable_silly_warnings.h diff --git a/common/env.cpp b/common/env.cpp index 684273d9e..817553c7c 100644 --- a/common/env.cpp +++ b/common/env.cpp @@ -159,7 +159,7 @@ const std::wstring& version() EXPAND_AND_QUOTE(CASPAR_GEN) "." EXPAND_AND_QUOTE(CASPAR_MAYOR) "." EXPAND_AND_QUOTE(CASPAR_MINOR) "." - EXPAND_AND_QUOTE(CASPAR_REV) " " + CASPAR_REV " " CASPAR_TAG); return ver; } diff --git a/gitrev.bat b/gitrev.bat new file mode 100644 index 000000000..d4cc6dd7c --- /dev/null +++ b/gitrev.bat @@ -0,0 +1,9 @@ +@ECHO OFF +for /f "tokens=*" %%a in ('git rev-parse --verify --short HEAD') do ( + set TEMPRESPONSE=%%a +) +COPY "%~dp0\version.tmpl" "%~dp0\version.h" /Y +ECHO #define CASPAR_REV "%TEMPRESPONSE%" >> "%~dp0\version.h" +ECHO gitrev.bat: %TEMPRESPONSE% +SET TEMPRESPONSE= +exit /b 0 \ No newline at end of file diff --git a/shell/shell.rc b/shell/shell.rc index cb6e9fd131ab327576299b3a5d8a5903840bcea6..f2f5f61d8ec63bf3c761c80315918747069426ba 100644 GIT binary patch delta 44 xcmdm{dP-%35DTNhWL1{($yZo}HXmR)!!%ilMP@P=hsfp!>?&Z+W*4p^4gf+*4Kx4% delta 70 zcmX@5vQ2e^5X-;VabEBH&0=?!Zi5~n*n