Skip to content

Commit 4973726

Browse files
PhilipOakleyttaylorr
authored andcommitted
glossary: add "commit graph" description
Git has an additional "commit graph" capability that supplements the normal commit object's directed acyclic graph (DAG). The supplemental commit graph file is designed for speed of access. Describe the commit graph both from the normative DAG view point and from the commit graph file perspective. Also, clarify the link between the branch ref and branch tip by linking to the `ref` glossary entry, matching this commit graph entry. The commit-graph file is also distinguished by its hyphenation. Subsequent commit catches the few cases where the hyphenation of commit-graph was missing. Signed-off-by: Philip Oakley <[email protected]> Signed-off-by: Taylor Blau <[email protected]>
1 parent fa8e8d5 commit 4973726

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

Documentation/glossary-content.txt

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
[[def_branch]]branch::
2121
A "branch" is a line of development. The most recent
2222
<<def_commit,commit>> on a branch is referred to as the tip of
23-
that branch. The tip of the branch is referenced by a branch
23+
that branch. The tip of the branch is <<def_ref,referenced>> by a branch
2424
<<def_head,head>>, which moves forward as additional development
2525
is done on the branch. A single Git
2626
<<def_repository,repository>> can track an arbitrary number of
@@ -75,6 +75,21 @@ state in the Git history, by creating a new commit representing the current
7575
state of the <<def_index,index>> and advancing <<def_HEAD,HEAD>>
7676
to point at the new commit.
7777

78+
[[def_commit_graph_general]]commit graph concept, representations and usage::
79+
A synonym for the <<def_DAG,DAG>> structure formed by the commits
80+
in the object database, <<def_ref,referenced>> by branch tips,
81+
using their <<def_chain,chain>> of linked commits.
82+
This structure is the definitive commit graph. The
83+
graph can be represented in other ways, e.g. the
84+
<<def_commit_graph_file,"commit-graph" file>>.
85+
86+
[[def_commit_graph_file]]commit-graph file::
87+
The "commit-graph" (normally hyphenated) file is a supplemental
88+
representation of the <<def_commit_graph_general,commit graph>>
89+
which accelerates commit graph walks. The "commit-graph" file is
90+
stored either in the .git/objects/info directory or in the info
91+
directory of an alternate object database.
92+
7893
[[def_commit_object]]commit object::
7994
An <<def_object,object>> which contains the information about a
8095
particular <<def_revision,revision>>, such as <<def_parent,parents>>, committer,

0 commit comments

Comments
 (0)