Versions in this module Expand all Collapse all v0 v0.44.0 Aug 25, 2023 v0.0.1 Oct 9, 2023 Changes in this version + type Client struct + func NewClient(cacheDir string, quiet bool, opts ...Option) *Client + func (c *Client) Download(ctx context.Context, dst string, opt types.RegistryOptions) error + func (c *Client) NeedsUpdate(cliVersion string, skip bool) (bool, error) + type MockOperation struct + func (_m *MockOperation) ApplyDownloadExpectation(e OperationDownloadExpectation) + func (_m *MockOperation) ApplyDownloadExpectations(expectations []OperationDownloadExpectation) + func (_m *MockOperation) ApplyNeedsUpdateExpectation(e OperationNeedsUpdateExpectation) + func (_m *MockOperation) ApplyNeedsUpdateExpectations(expectations []OperationNeedsUpdateExpectation) + func (_m *MockOperation) Download(ctx context.Context, dst string, opt types.RegistryOptions) error + func (_m *MockOperation) NeedsUpdate(cliVersion string, skip bool) (bool, error) + type Operation interface + Download func(ctx context.Context, dst string, opt types.RegistryOptions) (err error) + NeedsUpdate func(cliVersion string, skip bool) (need bool, err error) + type OperationDownloadArgs struct + Ctx context.Context + CtxAnything bool + Dst string + DstAnything bool + type OperationDownloadExpectation struct + Args OperationDownloadArgs + Returns OperationDownloadReturns + type OperationDownloadReturns struct + Err error + type OperationNeedsUpdateArgs struct + CliVersion string + CliVersionAnything bool + Skip bool + SkipAnything bool + type OperationNeedsUpdateExpectation struct + Args OperationNeedsUpdateArgs + Returns OperationNeedsUpdateReturns + type OperationNeedsUpdateReturns struct + Err error + Need bool + type Option func(*options) + func WithClock(c clock.Clock) Option + func WithDBRepository(dbRepository string) Option + func WithOCIArtifact(art *oci.Artifact) Option