version

package
v0.50.0 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package version carries build metadata, injected at link time via -ldflags.

Index

Constants

This section is empty.

Variables

View Source
var (
	Version = "dev"
	Commit  = "none"
	Date    = "unknown"
)

These are overridden at build time (see Makefile).

Functions

func String

func String() string

String returns a human-readable version line.

Types

type Info added in v0.32.0

type Info struct {
	Version string `json:"version"`
	Commit  string `json:"commit"`
	Built   string `json:"built"`
	Go      string `json:"go"`
}

Info is the build metadata in structured form, for machine consumers.

func Current added in v0.32.0

func Current() Info

Current returns the build metadata this binary was stamped with.

Jump to

Keyboard shortcuts

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