add the git prefix to the long version output

Tested on MacOS, written and not tested for Linux, not attempted for Windows
This commit is contained in:
nhkeni
2024-06-19 12:28:13 -04:00
parent 0cc134bb95
commit a8b5e88744
6 changed files with 23 additions and 1 deletions

View File

@@ -58,6 +58,10 @@ getversionstring(char *buf, size_t bufsz)
"%sbranch:%s",
c++ ? "," : "", nomakedefs.git_branch);
#endif
if (nomakedefs.git_prefix)
Snprintf(eos(buf), (bufsz - strlen(buf)) - 1,
"%sprefix:%s",
c++ ? "," : "", nomakedefs.git_prefix);
if (c)
Snprintf(eos(buf), (bufsz - strlen(buf)) - 1,
"%s", ")");