mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-22 17:49:43 +01:00
Fix %cs showing instead of commit date on Windows (or older git?)
Whenever I'd compile on Windows, I'd see the literal text "%cs" in the main menu instead of the commit date. I never thought much of it (at least it runs, and the date only shows up in development builds). Now that I've also seen a screenshot from Terry with it, I decided to look into it further. Looks like it's a format string that our gits on Windows aren't recognizing for whatever reason - probably because they're too old. I have git version 2.23.0.windows.1, and checking its help page for `git log`, under PRETTY FORMATS, %cs is missing as an option, while some other options are still there. So the option was probably added sometime between that version and 2.34.1, which is the one I have on Linux, where %cs does work. Luckily, %cd with --date=short seems equivalent, and better supported, so we can just use that instead.
This commit is contained in:
parent
1e5a737089
commit
1d3173f5c1
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@ EXECUTE_PROCESS(
|
||||||
)
|
)
|
||||||
|
|
||||||
EXECUTE_PROCESS(
|
EXECUTE_PROCESS(
|
||||||
COMMAND "${GIT_EXECUTABLE}" log -1 --format=%cs
|
COMMAND "${GIT_EXECUTABLE}" log -1 --format=%cd --date=short
|
||||||
OUTPUT_VARIABLE COMMIT_DATE
|
OUTPUT_VARIABLE COMMIT_DATE
|
||||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue