diff options
author | Andrew Thornton <art27@cantab.net> | 2023-10-08 15:49:51 +0100 |
---|---|---|
committer | Andrew Thornton <art27@cantab.net> | 2023-10-12 16:40:38 +0100 |
commit | 69b88d9bda44ebfe1d56a7624b956d9e20818c0e (patch) | |
tree | b6a17322552d0cdade956d3c4e0d6c14e49cf60e /plumbing/object/commitgraph/commitnode.go | |
parent | 623c6df4280e22f88f4aabc3c0a8ae2808d33a1b (diff) | |
download | go-git-69b88d9bda44ebfe1d56a7624b956d9e20818c0e.tar.gz |
plumbing: commitgraph, Add generation v2 support
This PR adds in support for generation v2 support and a couple of new
walkers to match --date-order etc options on log. This PR also fixes a
bug in the chain code and adds more tests.
Signed-off-by: Andrew Thornton <art27@cantab.net>
Diffstat (limited to 'plumbing/object/commitgraph/commitnode.go')
-rw-r--r-- | plumbing/object/commitgraph/commitnode.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/plumbing/object/commitgraph/commitnode.go b/plumbing/object/commitgraph/commitnode.go index d92c906..47227d4 100644 --- a/plumbing/object/commitgraph/commitnode.go +++ b/plumbing/object/commitgraph/commitnode.go @@ -29,6 +29,10 @@ type CommitNode interface { // Generation returns the generation of the commit for reachability analysis. // Objects with newer generation are not reachable from objects of older generation. Generation() uint64 + // GenerationV2 stores the corrected commit date for the commits + // It combines the contents of the GDA2 and GDO2 sections of the commit-graph + // with the commit time portion of the CDAT section. + GenerationV2() uint64 // Commit returns the full commit object from the node Commit() (*object.Commit, error) } |