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

Function DecodeTree

plumbing/object/tree.go:59–66  ·  view source on GitHub ↗

DecodeTree decodes an encoded object into a *Tree and associates it to the given object storer.

(s storer.EncodedObjectStorer, o plumbing.EncodedObject)

Source from the content-addressed store, hash-verified

57// DecodeTree decodes an encoded object into a *Tree and associates it to the
58// given object storer.
59func DecodeTree(s storer.EncodedObjectStorer, o plumbing.EncodedObject) (*Tree, error) {
60 t := &Tree{s: s}
61 if err := t.Decode(o); err != nil {
62 return nil, err
63 }
64
65 return t, nil
66}
67
68// TreeEntry represents a file
69type TreeEntry struct {

Callers 4

GetTreeFunction · 0.85
NextMethod · 0.85
ForEachMethod · 0.85
DecodeObjectFunction · 0.85

Calls 1

DecodeMethod · 0.95

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…