archive

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2026 License: MIT Imports: 17 Imported by: 0

Documentation

Overview

Package archive verifies and installs platform release archives.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BinaryChecker

type BinaryChecker = process.BinaryChecker

BinaryChecker aliases the process-level candidate validation contract.

type BinaryCheckerFunc

type BinaryCheckerFunc = process.BinaryCheckerFunc

BinaryCheckerFunc aliases the process-level test adapter.

type Release

type Release = model.Release

Release 与 ReleaseAsset 保持 archive 包内部使用同一 wire model。

type ReleaseAsset

type ReleaseAsset = model.ReleaseAsset

type ReleaseInstaller

type ReleaseInstaller interface {
	Install(context.Context, model.Release) error
}

ReleaseInstaller installs an already verified release for the current platform.

func NewReleaseInstaller

func NewReleaseInstaller(options ReleaseInstallerOptions) ReleaseInstaller

NewReleaseInstaller creates the production archive updater. Every write is delayed until the archive checksum and the embedded binary version both match.

type ReleaseInstallerOptions

type ReleaseInstallerOptions struct {
	HTTPClient        *http.Client
	ExecutablePath    func() (string, error)
	GOOS              string
	GOARCH            string
	BinaryChecker     process.BinaryChecker
	Replacer          func(string, string) error
	AssetURLValidator func(model.Release, model.ReleaseAsset) error
}

ReleaseInstallerOptions injects system boundaries for deterministic tests.

Jump to

Keyboard shortcuts

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