mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-10-02 02:43:44 +00:00
feat: log the build identifier at startup and show it on the dashboard About page
Every server logs BuildInfo's build string as its version; the About page also shows the build kind and commit, and log bundles name the build. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -32,6 +32,15 @@ namespace BuildInfo {
|
||||
return (static_cast<uint8_t>(buildKind) & BUILD_KIND_MASK) | (dirty ? DIRTY_FLAG : 0);
|
||||
}
|
||||
|
||||
inline std::string_view BuildKindName() {
|
||||
switch (buildKind) {
|
||||
case eBuildKind::LOCAL: return "Local";
|
||||
case eBuildKind::CI: return "CI";
|
||||
case eBuildKind::RELEASE: return "Release";
|
||||
default: return "Unknown";
|
||||
}
|
||||
}
|
||||
|
||||
// The first 32 bits (8 hex digits) of the commit hash, 0 without git.
|
||||
inline uint32_t CommitPrefix() {
|
||||
uint32_t value = 0;
|
||||
|
||||
Reference in New Issue
Block a user