From e7e74bb8abf266f84181bb7ba2c7365d2ee56a70 Mon Sep 17 00:00:00 2001 From: Misa Date: Mon, 22 Aug 2022 21:27:20 -0700 Subject: [PATCH] Add commit hash & date to `-version` flag output This prints the commit hash and date in the same order as they are printed on the title screen. --- desktop_version/src/main.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/desktop_version/src/main.cpp b/desktop_version/src/main.cpp index 41d02462..0ff3d587 100644 --- a/desktop_version/src/main.cpp +++ b/desktop_version/src/main.cpp @@ -388,8 +388,11 @@ int main(int argc, char *argv[]) if (ARG("-version")) { /* Just print the version and exit. No vlogging. */ - /* TODO: Also print commit date and hash, if applicable. */ puts("VVVVVV " RELEASE_VERSION); +#ifdef INTERIM_VERSION_EXISTS + puts(COMMIT_DATE); + puts(INTERIM_COMMIT); +#endif VVV_exit(0); } else if (ARG("-renderer"))