MCPcopy Index your code
hub / github.com/go-git/go-git / NewObjectStorage

Function NewObjectStorage

storage/filesystem/object.go:40–42  ·  view source on GitHub ↗

NewObjectStorage creates a new ObjectStorage with the given .git directory and cache.

(dir *dotgit.DotGit, objectCache cache.Object)

Source from the content-addressed store, hash-verified

38
39// NewObjectStorage creates a new ObjectStorage with the given .git directory and cache.
40func NewObjectStorage(dir *dotgit.DotGit, objectCache cache.Object) *ObjectStorage {
41 return NewObjectStorageWithOptions(dir, objectCache, Options{})
42}
43
44// NewObjectStorageWithOptions creates a new ObjectStorage with the given .git directory, cache and extra options
45func NewObjectStorageWithOptions(dir *dotgit.DotGit, objectCache cache.Object, ops Options) *ObjectStorage {

Callers 15

EncodedObjectMethod · 0.70
TestGetFromObjectFileMethod · 0.70
TestGetFromPackfileMethod · 0.70
TestMismatchIdxFileMethod · 0.70
TestIterMethod · 0.70
TestIterWithTypeMethod · 0.70
TestHashesWithPrefixMethod · 0.70

Calls 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…