diff options
| author | 2025-11-16 00:00:00 +0000 | |
|---|---|---|
| committer | 2025-11-16 00:00:00 +0000 | |
| commit | 503f2f1bbc69be553d04c621c7ec33931cc1f57d (patch) | |
| tree | 289b2ea2dc589d6ce7efc3e44966eabb6739d3f2 /obj_commit.go | |
| parent | README: benmarking -> test (diff) | |
| signature | ||
Add a little bit more of documentation
Diffstat (limited to 'obj_commit.go')
| -rw-r--r-- | obj_commit.go | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/obj_commit.go b/obj_commit.go index 9953f690..524ef7bd 100644 --- a/obj_commit.go +++ b/obj_commit.go @@ -8,11 +8,19 @@ import ( // Commit represents a Git commit object. type Commit struct { - Tree Hash - Parents []Hash - Author Ident - Committer Ident - Message []byte + // Tree represents the tree hash referenced by the commit. + Tree Hash + // Parents represents the parent commit hashes. + // Commits that have 0 parents are root commits. + // Commits that have >= 2 parents are merge commits. + Parents []Hash + // Author represents the author of the commit. + Author Ident + // Committer represents the committer of the commit. + Committer Ident + // Message represents the commit message. + Message []byte + // ExtraHeaders holds any extra headers present in the commit. ExtraHeaders []ExtraHeader } |
