upgrade

package
v0.6.321 Latest Latest
Warning

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

Go to latest
Published: Mar 14, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package upgrade provides the brev upgrade command.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewCmdUpgrade

func NewCmdUpgrade(t *terminal.Terminal, versionStore VersionStore) *cobra.Command

NewCmdUpgrade creates the brev upgrade command.

Types

type Detector added in v0.6.320

type Detector interface {
	Detect() InstallMethod
}

Detector determines how brev was installed.

type InstallMethod added in v0.6.320

type InstallMethod int

InstallMethod represents how brev was installed on the system.

const (
	// InstallMethodDirect means brev was installed via direct binary download.
	InstallMethodDirect InstallMethod = 0
	// InstallMethodBrew means brev was installed via Homebrew.
	InstallMethodBrew InstallMethod = 1
)

type SkillInstaller added in v0.6.320

type SkillInstaller interface {
	InstallSkill(t *terminal.Terminal) error
}

SkillInstaller updates agent skill files after a binary upgrade.

type SystemDetector added in v0.6.320

type SystemDetector struct{}

SystemDetector checks the actual system for install method.

func (SystemDetector) Detect added in v0.6.320

func (SystemDetector) Detect() InstallMethod

Detect checks whether brev was installed via Homebrew or direct download.

type SystemUpgrader added in v0.6.320

type SystemUpgrader struct{}

SystemUpgrader executes upgrade commands on the real system.

func (SystemUpgrader) UpgradeViaBrew added in v0.6.320

func (SystemUpgrader) UpgradeViaBrew(t *terminal.Terminal) error

UpgradeViaBrew runs "brew upgrade brev" with output connected to the terminal.

func (SystemUpgrader) UpgradeViaInstallScript added in v0.6.320

func (SystemUpgrader) UpgradeViaInstallScript(t *terminal.Terminal) error

UpgradeViaInstallScript runs the upstream install-latest.sh script via sudo.

type Upgrader added in v0.6.320

type Upgrader interface {
	UpgradeViaBrew(t *terminal.Terminal) error
	UpgradeViaInstallScript(t *terminal.Terminal) error
}

Upgrader executes the actual upgrade process.

type VersionStore added in v0.6.320

type VersionStore interface {
	GetLatestReleaseMetadata() (*store.GithubReleaseMetadata, error)
}

VersionStore fetches the latest release metadata from GitHub.

Jump to

Keyboard shortcuts

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