Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Result ¶
type Result struct {
Latest string // latest version tag (e.g. "0.2.0")
Current string // current running version
UpdateURL string // URL to the release page
}
Result holds the outcome of an update check.
func Check ¶
Check queries the GitHub API for the latest release of owner/repo and compares it with the current version. It returns nil on any error (network failure, bad JSON, etc.) so callers can safely ignore update checks.
func (*Result) NeedsUpdate ¶
NeedsUpdate returns true if the latest version is newer than current.
func (*Result) UpgradeCommand ¶
UpgradeCommand returns the best-effort command to update the current installation.
Click to show internal directories.
Click to hide internal directories.