updater

package
v2.10.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 29, 2026 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrDevelopmentVersion = errors.New("update check skipped for development version")

Functions

func Apply

func Apply(ctx context.Context, platformID string) (string, error)

func CheckAndNotify

func CheckAndNotify(
	ctx context.Context,
	cfg *config.Instance,
	platformID string,
	inboxSvc *inbox.Service,
	waitFn func(int) bool,
	checkFn CheckFn,
	managedInstall bool,
)

CheckAndNotify checks for updates and posts an inbox message if one is available. Intended to be called as a fire-and-forget goroutine on startup.

Types

type CheckFn

type CheckFn func(ctx context.Context, platformID string) (*Result, error)

CheckFn is the signature for a function that checks for updates.

type Result

type Result struct {
	CurrentVersion  string
	LatestVersion   string
	ReleaseNotes    string
	UpdateAvailable bool
}

func Check

func Check(ctx context.Context, platformID string) (*Result, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL