buildinfo

package
v0.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2026 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package buildinfo formats the runtime version banner shared by all four deadzone binaries. Each cmd/*/main.go owns its own package-level version/commit/date vars (they have to live in each main package so `-ldflags -X main.version=…` can target them) and calls Format to render the banner for the -version flag and startup logs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Format

func Format(name, version, commit, date string) string

Format renders the standard "<name> <version> (<commit>, built <date>)" banner, e.g.:

deadzone-server v0.1.0 (abc1234, built 2026-04-12T12:34:56Z)

The three value strings come from ldflags injection at release build time (see justfile's build-release recipe) or from their default "dev" / "unknown" fallbacks when the binary was built without -X.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL