updates

package
v0.0.36 Latest Latest
Warning

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

Go to latest
Published: May 23, 2025 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package updates contains logic for checking if an update is available for ToolHive.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UpdateChecker

type UpdateChecker interface {
	// CheckLatestVersion checks if a new version of ToolHive is available
	// and prints the result to the console.
	CheckLatestVersion() error
}

UpdateChecker is an interface for checking if a new version of ToolHive is available.

func NewUpdateChecker

func NewUpdateChecker(versionClient VersionClient) (UpdateChecker, error)

NewUpdateChecker creates a new instance of UpdateChecker.

type VersionClient

type VersionClient interface {
	GetLatestVersion(instanceID string, currentVersion string) (string, error)
}

VersionClient is an interface for calling the update service API.

func NewVersionClient

func NewVersionClient() VersionClient

NewVersionClient creates a new instance of VersionClient.

Jump to

Keyboard shortcuts

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