Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrNoCacheFound = errors.New("cached version not found") ErrNoStoreFound = errors.New("cache store not found") )
Functions ¶
func OpenOrCreate ¶
OpenOrCreate expects a directory cache with populated indicies for each store or for no directory to exist. If a directory doesn't exist, the function will attempt to create one. Any non-indexed directories within will cause an error to be returned. A valid Cacher will be returned if nil error is returned.
Types ¶
type Cacher ¶
type Cacher interface { // Cache a single binary artifact using a namespace and version located at path Cache(namespace, version, path string) error // Get the path for an already cached binary if one exists. An error will // be returned for any case that causes the Cacher to not provide a valid path Get(namespace, version string) (string, error) }
Cacher is used by the builder package to copy the binary of expensive builds.
Click to show internal directories.
Click to hide internal directories.