Initial check in.
This commit is contained in:
31
version.bat
Normal file
31
version.bat
Normal file
@@ -0,0 +1,31 @@
|
||||
rem
|
||||
rem Copyright 2005-2013 Vahagn Khachatryan.
|
||||
rem
|
||||
rem This program is free software; you can redistribute it and/or modify
|
||||
rem it under the terms of the GNU General Public License as published by
|
||||
rem the Free Software Foundation; either version 2 of the License, or
|
||||
rem (at your option) any later version.
|
||||
rem
|
||||
rem This program is distributed in the hope that it will be useful,
|
||||
rem but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
rem MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
rem GNU General Public License for more details.
|
||||
rem
|
||||
|
||||
rem
|
||||
rem Generate res\values\version.xml for windows.
|
||||
rem
|
||||
|
||||
|
||||
set VERSION_XML=res\values\version.xml
|
||||
|
||||
echo ^<?xml version="1.0" encoding="utf-8"?^> > %VERSION_XML%
|
||||
echo ^<resources^> >> %VERSION_XML%
|
||||
for /F "delims=" %%i in ('"git describe --tags --long --dirty=-x --abbrev=8"') do set VERSION=%%i
|
||||
echo ^<string name="gitversion"^>%VERSION%^</string^> >> %VERSION_XML%
|
||||
for /F "delims=" %%i in ('"git rev-parse HEAD"') do set GITHASH=%%i
|
||||
echo ^<string name="githash"^>%GITHASH%^</string^> >> %VERSION_XML%
|
||||
for /F "delims=" %%i in ('"%USERPROFILE%\bin\date.exe -R"') do set BUILDDATE=%%i
|
||||
echo ^<string name="builddate"^>%BUILDDATE%^</string^> >> %VERSION_XML%
|
||||
echo ^</resources^> >> %VERSION_XML%
|
||||
|
||||
Reference in New Issue
Block a user