MCPcopy
hub / github.com/go-git/go-git / ObjectPack

Method ObjectPack

storage/filesystem/dotgit/dotgit.go:309–316  ·  view source on GitHub ↗

ObjectPack returns a fs.File of the given packfile

(hash plumbing.Hash)

Source from the content-addressed store, hash-verified

307
308// ObjectPack returns a fs.File of the given packfile
309func (d *DotGit) ObjectPack(hash plumbing.Hash) (billy.File, error) {
310 err := d.hasPack(hash)
311 if err != nil {
312 return nil, err
313 }
314
315 return d.objectPackOpen(hash, `pack`)
316}
317
318// ObjectPackIdx returns a fs.File of the index file for a given packfile
319func (d *DotGit) ObjectPackIdx(hash plumbing.Hash) (billy.File, error) {

Callers 10

packfileMethod · 0.80
buildPackfileItersMethod · 0.80
TestPackfileIterMethod · 0.80
BenchmarkPackfileIterFunction · 0.80
TestObjectPackMethod · 0.80

Calls 2

hasPackMethod · 0.95
objectPackOpenMethod · 0.95