summaryrefslogtreecommitdiff
path: root/Documentation/git-commit-graph.txt
diff options
context:
space:
mode:
authorLibravatar Derrick Stolee <dstolee@microsoft.com>2018-06-27 09:24:32 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-06-27 10:27:05 -0700
commit283e68c72f49e6cfbae53cb5547d5b399ed25d1a (patch)
treea6fd95c90d49b9cb99b5d11c1f8e224d2a9a667c /Documentation/git-commit-graph.txt
parentcommit-graph: load a root tree from specific graph (diff)
downloadtgif-283e68c72f49e6cfbae53cb5547d5b399ed25d1a.tar.xz
commit-graph: add 'verify' subcommand
If the commit-graph file becomes corrupt, we need a way to verify that its contents match the object database. In the manner of 'git fsck' we will implement a 'git commit-graph verify' subcommand to report all issues with the file. Add the 'verify' subcommand to the 'commit-graph' builtin and its documentation. The subcommand is currently a no-op except for loading the commit-graph into memory, which may trigger run-time errors that would be caught by normal use. Add a simple test that ensures the command returns a zero error code. If no commit-graph file exists, this is an acceptable state. Do not report any errors. Helped-by: Ramsay Jones <ramsay@ramsayjones.plus.com> Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/git-commit-graph.txt')
-rw-r--r--Documentation/git-commit-graph.txt6
1 files changed, 6 insertions, 0 deletions
diff --git a/Documentation/git-commit-graph.txt b/Documentation/git-commit-graph.txt
index 4c97b555cc..a222cfab08 100644
--- a/Documentation/git-commit-graph.txt
+++ b/Documentation/git-commit-graph.txt
@@ -10,6 +10,7 @@ SYNOPSIS
--------
[verse]
'git commit-graph read' [--object-dir <dir>]
+'git commit-graph verify' [--object-dir <dir>]
'git commit-graph write' <options> [--object-dir <dir>]
@@ -52,6 +53,11 @@ existing commit-graph file.
Read a graph file given by the commit-graph file and output basic
details about the graph file. Used for debugging purposes.
+'verify'::
+
+Read the commit-graph file and verify its contents against the object
+database. Used to check for corrupted data.
+
EXAMPLES
--------