diff options
| author | George Hazan <george.hazan@gmail.com> | 2025-03-14 16:41:28 +0300 |
|---|---|---|
| committer | George Hazan <george.hazan@gmail.com> | 2025-03-14 16:41:28 +0300 |
| commit | 48cc2a3ce4a1c15147e7cd8ff271c001e9c7317e (patch) | |
| tree | 610dcc25ae7e40d0dd0e86b2591d073109453385 | |
| parent | 60cb291620f95d588c51f12a944e143dd3c86098 (diff) | |
core to be rebuilt only when it's changed
| -rw-r--r-- | build/make_ver.bat | 5 | ||||
| -rw-r--r-- | build/make_ver_stable.bat | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/build/make_ver.bat b/build/make_ver.bat index 32d401d944..3699c6670a 100644 --- a/build/make_ver.bat +++ b/build/make_ver.bat @@ -2,8 +2,9 @@ cd /d %~dp0
for /F "tokens=2,3" %%i in (..\include\m_version.h) do if "%%i"=="MIRANDA_VERSION_FILEVERSION" (set OldVer=%%j)
-for /F %%i in ('git rev-list --count HEAD') do set Revision=%%i
-for /F %%i in ('git rev-parse --short HEAD') do set Hash=%%i
+for /F %%i in ('git rev-list --count HEAD ../src') do set Revision=%%i
+for /F %%i in ('git rev-list --max-count=1 HEAD ../src') do set HashAll=%%i
+set Hash=%HashAll:~0,7%
REM Fix building not-svn repository (e.g., Git mirror)
if "%Revision:~0,11%" == "Unversioned" (set Revision=0)
diff --git a/build/make_ver_stable.bat b/build/make_ver_stable.bat index fd555bc0e2..7d7600aaca 100644 --- a/build/make_ver_stable.bat +++ b/build/make_ver_stable.bat @@ -2,8 +2,9 @@ cd /d %~dp0 for /F "tokens=2,3" %%i in (..\include\m_version.h) do if "%%i"=="MIRANDA_VERSION_FILEVERSION" (set OldVer=%%j) -for /F %%i in ('git rev-list --count HEAD') do set Revision=%%i -for /F %%i in ('git rev-parse --short HEAD') do set Hash=%%i +for /F %%i in ('git rev-list --count HEAD ../src') do set Revision=%%i +for /F %%i in ('git rev-list --max-count=1 HEAD ../src') do set HashAll=%%i +set Hash=%HashAll:~0,7% REM Fix building not-svn repository (e.g., Git mirror) if "%Revision:~0,11%" == "Unversioned" (set Revision=0) |
