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

Method DiffContext

plumbing/object/tree.go:430–432  ·  view source on GitHub ↗

DiffContext returns a list of changes between this tree and the provided one Error will be returned if context expires. Provided context must be non nil. NOTE: Since version 5.1.0 the renames are correctly handled, the settings used are the recommended options DefaultDiffTreeOptions.

(ctx context.Context, to *Tree)

Source from the content-addressed store, hash-verified

428// NOTE: Since version 5.1.0 the renames are correctly handled, the settings
429// used are the recommended options DefaultDiffTreeOptions.
430func (t *Tree) DiffContext(ctx context.Context, to *Tree) (Changes, error) {
431 return DiffTreeWithOptions(ctx, t, to, DefaultDiffTreeOptions)
432}
433
434// Patch returns a slice of Patch objects with all the changes between trees
435// in chunks. This representation can be used to create several diff outputs.

Callers 3

DiffMethod · 0.95
PatchContextMethod · 0.95
TestTreeDiffMethod · 0.80

Calls 1

DiffTreeWithOptionsFunction · 0.85

Tested by 1

TestTreeDiffMethod · 0.64