version

package
v0.4.1-beta.14 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Version   = "dev"
	Commit    = "unknown"
	Date      = "unknown"
	GoVersion = runtime.Version()
)

These will be set by GoReleaser at build time

Functions

func GetFullVersion

func GetFullVersion() string

GetFullVersion returns a detailed version string

Example: "v1.0.0 (commit: a1b2c3d4, built: 2023-01-01T00:00:00Z, go: go1.19.1)"

func GetVersion

func GetVersion() string

GetVersion returns just the version string

Example: "v1.0.0" or "dev-a1b2c3d4"

Types

type BuildInfo

type BuildInfo struct {
	Version   string `json:"version"`
	Commit    string `json:"commit"`
	Date      string `json:"date"`
	GoVersion string `json:"go_version"`
}

BuildInfo contains version information

func GetBuildInfo

func GetBuildInfo() BuildInfo

GetBuildInfo returns the build information

Jump to

Keyboard shortcuts

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