0 votes
in Git by

What does a Commit object contain?

2 Answers

0 votes
by
The commit object contains the top-level tree object hash, parent commits hash(if any), author and committer information, commit date and commit message.

You can view this through the git log command.

Example:

commit object
0 votes
by

Commit object contain the following components:

It contains a set of files, representing the state of a project at a given point of time reference to parent commit objects

An SHAI name, a 40-character string that uniquely identifies the commit object (also called as hash).

Related questions

0 votes
asked Jan 14, 2020 in QuickTest Professional (QTP) by GeorgeBell
0 votes
asked Aug 24, 2023 in Git by JackTerrance
...