version

package
v0.0.0-...-9f55e2f Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// These will be set via -ldflags during build
	GitRepo   string
	GitBranch string
	GitCommit string
	BuildTime string
)

Functions

This section is empty.

Types

type Info

type Info struct {
	GitRepo   string           `json:"gitRepo,omitempty"`
	GitBranch string           `json:"gitBranch,omitempty"`
	GitCommit string           `json:"gitCommit,omitempty"`
	BuildTime string           `json:"buildTime,omitempty"`
	BuildInfo *debug.BuildInfo `json:"buildInfo,omitempty"`
}

Info returns a struct containing all version information

func Get

func Get() Info

Get returns the version information

func (Info) Equal

func (v Info) Equal(other Info) bool

Equal checks if two version infos represent the same version Two versions are considered equal if they have the same git commit and build info settings.

Jump to

Keyboard shortcuts

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