caches

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeFingerPrint

func ComputeFingerPrint(clangTidyPath string, invocation *clang.TidyInvocation, wd string, args []string) ([]byte, error)

func GetFileSystemCachePath added in v0.3.0

func GetFileSystemCachePath() string

GetFileSystemCachePath gets the path to the directory to use for storing the cache. It defaults to ~/.ctcache/cache and can be overridden by setting CLANG_TIDY_CACHE_DIR environment variable.

Types

type Cacher

type Cacher interface {
	// Find contents of cache entry specified by digest.
	FindEntry(digest []byte) ([]byte, error)
	// Store contents into a cache entry specified by digest.
	SaveEntry(digest []byte, content []byte) error
}

type FileSystemCache

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

func NewFsCache

func NewFsCache() *FileSystemCache

func (*FileSystemCache) FindEntry

func (c *FileSystemCache) FindEntry(digest []byte) ([]byte, error)

func (*FileSystemCache) SaveEntry

func (c *FileSystemCache) SaveEntry(digest []byte, content []byte) error

type GcsConfiguration added in v0.2.0

type GcsConfiguration struct {
	BucketId string `json:"bucket_id"`
}

type GoogleCloudStorageCache added in v0.2.0

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

func NewGcsCache added in v0.2.0

func NewGcsCache(cfg *GcsConfiguration) (*GoogleCloudStorageCache, error)

func (*GoogleCloudStorageCache) FindEntry added in v0.2.0

func (c *GoogleCloudStorageCache) FindEntry(digest []byte) ([]byte, error)

func (*GoogleCloudStorageCache) SaveEntry added in v0.2.0

func (c *GoogleCloudStorageCache) SaveEntry(digest []byte, content []byte) error

Jump to

Keyboard shortcuts

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