Documentation
¶
Overview ¶
Package updatecheck looks for a newer gofer release (gofer-6x2n, docs/design/2026-10-13-update-check-design.md): the latest GitHub release by default, or a mirror's latest.yaml. It only reports; it never downloads or installs anything.
Index ¶
Constants ¶
const AppName = "gofer"
AppName is the {name} of the release artifacts.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Checker ¶
type Checker struct {
// contains filtered or unexported fields
}
Checker checks one source and keeps the latest result.
func New ¶
func New(current string, cfg func() config.UpdateConfig) *Checker
New builds a checker for the running version; cfg is read on every check, so a reload applies to the next one.
func (*Checker) Check ¶
Check runs one check now and returns (and keeps) its result. A failure is in Status.Error, never fatal.
type Status ¶
type Status struct {
Current string `json:"current"`
Latest string `json:"latest,omitempty"`
Newer bool `json:"newer"`
Source string `json:"source"`
CheckedAt int64 `json:"checked_at"`
ReleasedAt string `json:"released_at,omitempty"`
ReleaseURL string `json:"release_url,omitempty"`
DownloadURL string `json:"download_url,omitempty"`
Description string `json:"description,omitempty"`
Error string `json:"error,omitempty"`
}
Status is the result of the latest check.