Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Info ¶
type Info struct { GitVersion string `json:"gitVersion"` ModuleSum string `json:"moduleCheksum"` GitCommit string `json:"gitCommit"` GitTreeState string `json:"gitTreeState"` BuildDate string `json:"buildDate"` BuiltBy string `json:"builtBy"` GoVersion string `json:"goVersion"` Compiler string `json:"compiler"` Platform string `json:"platform"` ASCIIName string `json:"-"` Name string `json:"-"` Description string `json:"-"` URL string `json:"-"` }
Info provides the version info.
func GetVersionInfo ¶
GetVersionInfo represents known information on how this binary was built.
func (*Info) JSONString ¶
JSONString returns the JSON representation of the version info
type Option ¶
type Option func(i *Info)
Option can be used to customize the version after its gathered from the environment.
func WithASCIIName ¶
WithASCIIName allows you to add an ASCII art of the name.
func WithAppDetails ¶
WithAppDetails allows to set the app name and description.
func WithBuiltBy ¶
WithBuiltBy allows to set the builder name/builder system name.
Click to show internal directories.
Click to hide internal directories.