version

package
v0.0.0-...-8d28fdc Latest Latest
Warning

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

Go to latest
Published: Jun 22, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Version = GetVersion()
	Commit  = GetCommit()
	Date    = GetBuildDate()
)

Variables to store version information

Functions

func CheckVersionFlag

func CheckVersionFlag(args []string) bool

CheckVersionFlag checks if the version flag is present in args and prints version info if it is

func GetBuildDate

func GetBuildDate() string

GetBuildDate returns the current date in ISO 8601 format

func GetCommit

func GetCommit() string

GetCommit attempts to get the current git commit hash

func GetVersion

func GetVersion() (version string)

GetVersion attempts to get the version from git tags, falling back to a datetime format or "dev-UNKNOWN" if all else fails

func VersionString

func VersionString() string

VersionString returns a formatted version string

Types

This section is empty.

Jump to

Keyboard shortcuts

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