Versions in this module Expand all Collapse all v1 v1.23.14 Apr 4, 2026 Changes in this version + const CodeConfigFailed + const CodeInvalidInput + func HasUpdateConfig(cfg config.Config) bool v1.23.13 Mar 26, 2026 Changes in this version + const CodeAlreadyUpToDate + const CodeChannelSwitchDecline + const CodeDownloadFailed + const CodeElevationFailed + const CodeElevationRequired + const CodeNonStandardInstall + const CodePackageManagerFailed + const CodeReplaceFailed + const CodeSignatureInvalid + const CodeSkippedCI + const CodeSuccess + const CodeUnsupportedInstallMethod + const CodeVersionCheckFailed + const DefaultCheckIntervalDaily + const DefaultCheckIntervalStable + var ErrNeedsElevation = fmt.Errorf("applying staged update requires elevation") + var FeatureUpdate = alpha.MustFeatureKey("update") + func ApplyStagedUpdate() (string, error) + func CleanStagedUpdate() + func HasStagedUpdate() bool + func IsCacheValid(cache *CacheFile, channel Channel) bool + func IsPackageManagerInstall() bool + func PackageManagerUninstallCmd(installedBy installer.InstallType) string + func ParseDailyBuildNumber(version string) (int, error) + func ReadAppliedMarker() (string, error) + func RemoveAppliedMarker() + func SaveAutoUpdate(cfg config.Config, enabled bool) error + func SaveCache(cache *CacheFile) error + func SaveChannel(cfg config.Config, channel Channel) error + func SaveCheckIntervalHours(cfg config.Config, hours int) error + func StagedBinaryPath() (string, error) + func WriteAppliedMarker(fromVersion string) + type CacheFile struct + BuildNumber int + Channel string + ExpiresOn string + Version string + func LoadCache() (*CacheFile, error) + type Channel string + const ChannelDaily + const ChannelStable + func ParseChannel(s string) (Channel, error) + type Manager struct + func NewManager(commandRunner exec.CommandRunner, httpClient *http.Client) *Manager + func (m *Manager) CheckForUpdate(ctx context.Context, cfg *UpdateConfig, ignoreCache bool) (*VersionInfo, error) + func (m *Manager) StageUpdate(ctx context.Context, cfg *UpdateConfig) error + func (m *Manager) Update(ctx context.Context, cfg *UpdateConfig, writer io.Writer) error + type UpdateConfig struct + AutoUpdate bool + Channel Channel + CheckIntervalHours int + func LoadUpdateConfig(cfg config.Config) *UpdateConfig + func (c *UpdateConfig) DefaultCheckInterval() time.Duration + type UpdateError struct + Code string + Err error + func (e *UpdateError) Error() string + func (e *UpdateError) Unwrap() error + type VersionInfo struct + BuildNumber int + Channel Channel + HasUpdate bool + Version string