X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=Documentation%2Fgit-fsck.txt;h=287c4fc5e07ea753c2a3d93bf6480f41aac8c9af;hb=996869601594ffefb67238175055922340ced6f8;hp=9846c859cf3f4c76525aae124e0ef516fa55779f;hpb=bc9c3e0b932c5e14de749e07f5045197e7d6cd76;p=git.git diff --git a/Documentation/git-fsck.txt b/Documentation/git-fsck.txt index 9846c859c..287c4fc5e 100644 --- a/Documentation/git-fsck.txt +++ b/Documentation/git-fsck.txt @@ -9,7 +9,7 @@ git-fsck - Verifies the connectivity and validity of the objects in the database SYNOPSIS -------- [verse] -'git-fsck' [--tags] [--root] [--unreachable] [--cache] [--no-reflogs] +'git fsck' [--tags] [--root] [--unreachable] [--cache] [--no-reflogs] [--full] [--strict] [--verbose] [--lost-found] [*] DESCRIPTION @@ -21,7 +21,7 @@ OPTIONS :: An object to treat as the head of an unreachability trace. + -If no objects are given, git-fsck defaults to using the +If no objects are given, 'git-fsck' defaults to using the index file, all SHA1 references in .git/refs/*, and all reflogs (unless --no-reflogs is given) as heads. @@ -79,15 +79,16 @@ that aren't readable from any of the specified head nodes. So for example - git-fsck --unreachable HEAD $(cat .git/refs/heads/*) + git fsck --unreachable HEAD \ + $(git for-each-ref --format="%(objectname)" refs/heads) will do quite a _lot_ of verification on the tree. There are a few extra validity tests to be added (make sure that tree objects are -sorted properly etc), but on the whole if "git-fsck" is happy, you +sorted properly etc), but on the whole if 'git-fsck' is happy, you do have a valid tree. Any corrupt objects you will have to find in backups or other archives -(i.e., you can just remove them and do an "rsync" with some other site in +(i.e., you can just remove them and do an 'rsync' with some other site in the hopes that somebody else has the object you have corrupted). Of course, "valid tree" doesn't mean that it wasn't generated by some