dircache

package
v29.3.1 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCacheNotFound = errors.New("cache not found")

Functions

func ClearCache

func ClearCache() error

ClearCache remove the cache path.

Types

type Cache

type Cache struct {
	// contains filtered or unexported fields
}

func New

func New(cacheStorage cache.Storage, dir, specNamespace string) (Cache, error)

New creates a new Buf based on the installed binary.

func (Cache) CopyTo

func (c Cache) CopyTo(src, output string, keys ...string) (string, error)

CopyTo gets the cache folder based on the cache key from the storage and copies the folder to the output.

func (Cache) Save

func (c Cache) Save(src, key string) error

Save copies the source to the cache folder and saves the path into the storage based on the key.

Jump to

Keyboard shortcuts

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