Versions in this module Expand all Collapse all v0 v0.1.0 Nov 17, 2022 v0.0.3 Jun 21, 2019 Changes in this version + func Apply(opts ...Option) error + func RollbackError(err error) error + type Config struct + Architecture string + CurrentVersion string + Downloader Downloader + Log logrus.StdLogger + OperatingSystem string + PublicKey []byte + SourceRepo string + TargetFile string + Version string + func (c *Config) Validate() error + type Downloader interface + Configure func(*Config) error + FetchBinary func(spec *Spec, target string) error + FetchSpec func() (*Spec, error) + type HTTPDownloader struct + func (h *HTTPDownloader) Configure(c *Config) error + func (h *HTTPDownloader) FetchBinary(spec *Spec, target string) error + func (h *HTTPDownloader) FetchSpec() (spec *Spec, err error) + type Option func(*Config) error + func Arch(a string) Option + func CurrentVersion(v string) Option + func DownloadMethod(m Downloader) Option + func Logger(l logrus.StdLogger) Option + func OS(os string) Option + func PublicKey(k []byte) Option + func SourceRepo(r string) Option + func TargetFile(f string) Option + func Version(v string) Option + type Spec struct + BinaryPath string + BinaryURI *url.URL + Sha256Hash string + Signature string + func FetchSpec(opts ...Option) (*Spec, error)