Add the ability to skip generation of git and date data (#3800)

This can be done by setting the `CHATTERINO_SKIP_DATE_GEN` and `CHATTERINO_SKIP_GIT_GEN` environment variables
This commit is contained in:
pajlada
2022-06-05 16:44:20 +02:00
committed by GitHub
parent a95abc3421
commit 6c38d3ecab
2 changed files with 9 additions and 1 deletions
+4
View File
@@ -19,6 +19,10 @@ set(GIT_COMMIT "GIT-REPOSITORY-NOT-FOUND")
set(GIT_RELEASE "${PROJECT_VERSION}")
set(GIT_MODIFIED 0)
if (DEFINED ENV{CHATTERINO_SKIP_GIT_GEN})
return()
endif ()
if (GIT_EXECUTABLE)
execute_process(
COMMAND ${GIT_EXECUTABLE} rev-parse --is-inside-work-tree