From: TK3 Date: Thu, 28 Mar 2013 19:59:04 +0000 (-0400) Subject: gitrev.bat revision marking for server 2.1 X-Git-Tag: 2.1.0_Beta1~488^2^2 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=897bd3eb6961fd1576313a043ef32dbb700286f1;p=casparcg gitrev.bat revision marking for server 2.1 --- 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 cb6e9fd13..f2f5f61d8 100644 Binary files a/shell/shell.rc and b/shell/shell.rc differ diff --git a/version.tmpl b/version.tmpl index b5ca1ffa1..98c3d68b4 100644 --- a/version.tmpl +++ b/version.tmpl @@ -1,5 +1,4 @@ #define CASPAR_GEN 2 #define CASPAR_MAYOR 1 #define CASPAR_MINOR 0 -#define CASPAR_REV $WCREV$ #define CASPAR_TAG "UNSTABLE"