Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Version = "dev"
Version is set via ldflags at build time.
Functions ¶
func CheckForUpdate ¶ added in v0.0.2
func CheckForUpdate()
CheckForUpdate queries GitHub for the latest release and prints an update notice to stderr if a newer version exists. Fails silently on network errors or dev builds.
func Get ¶
func Get() string
Get returns the build version. If Version was not set via ldflags, it falls back to the module version from runtime/debug.ReadBuildInfo (populated automatically by go install ...@vX.Y.Z).
func PrintVersionWithUpdateCheck ¶ added in v0.0.2
func PrintVersionWithUpdateCheck()
PrintVersionWithUpdateCheck prints the current version and whether an update is available. Used by the `version` subcommand.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.