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

Method hasPack

storage/filesystem/dotgit/dotgit.go:551–567  ·  view source on GitHub ↗
(h plumbing.Hash)

Source from the content-addressed store, hash-verified

549}
550
551func (d *DotGit) hasPack(h plumbing.Hash) error {
552 if !d.options.ExclusiveAccess {
553 return nil
554 }
555
556 err := d.genPackList()
557 if err != nil {
558 return err
559 }
560
561 _, ok := d.packMap[h]
562 if !ok {
563 return ErrPackfileNotFound
564 }
565
566 return nil
567}
568
569func (d *DotGit) objectPath(h plumbing.Hash) string {
570 hex := h.String()

Callers 3

objectPackOpenMethod · 0.95
ObjectPackMethod · 0.95
ObjectPackIdxMethod · 0.95

Calls 1

genPackListMethod · 0.95

Tested by

no test coverage detected