Documentation
¶
Overview ¶
Package update implements a non-blocking notifier that lets the user know when a newer release of the CLI is available on GitHub. The latest version is fetched at most once per day and cached alongside the config so normal commands never pay a network cost.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Notify ¶
func Notify(current string, done <-chan struct{})
Notify prints an upgrade notice to stderr if the cached latest version is newer than current. It waits briefly for the background check to finish so a freshly fetched version can surface on the same run.
func StartBackgroundCheck ¶
func StartBackgroundCheck() <-chan struct{}
StartBackgroundCheck refreshes the cached latest version in the background if it is stale. It returns a channel that is closed once the check completes so the caller can briefly wait for an up-to-date result before exiting.
Types ¶
This section is empty.