git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 2/2] fsck: document msg-id

From
John Cai via GitGitGadget <gitgitgadget@gmail.com>
Date
Oct 24, 2022, 15:00 UTC
Message-ID
<3aec3d2c9ca65a37a367c3a7c9081bbd4cd44ae0.1666623639.git.gitgitgadget@gmail.com>
In-Reply-To
<pull.1369.git.git.1666623639.gitgitgadget@gmail.com>
From: John Cai <johncai86@gmail.com>

The git-config documentation lacks mention of specific <msg-id> that are supported. While git-help --config will display a list of these options, often developers' first instinct is to consult the git docs to find valid config values.

Add a section under the docs for fsck.<msg-id> with the msg-ids that git-fsck recognizes.

Signed-off-by: John Cai <johncai86@gmail.com>
---
 Documentation/config/fsck.txt |   5 ++
 Documentation/fsck-msgids.txt | 133 ++++++++++++++++++++++++++++++++++
 2 files changed, 138 insertions(+)
 create mode 100644 Documentation/fsck-msgids.txt
diff --git a/Documentation/config/fsck.txt b/Documentation/config/fsck.txt
index 450e8c38e34..b0632075f22 100644
--- a/Documentation/config/fsck.txt
+++ b/Documentation/config/fsck.txt
@@ -35,6 +35,11 @@ allow new instances of the same breakages go unnoticed.
 Setting an unknown `fsck.<msg-id>` value will cause fsck to die, but
 doing the same for `receive.fsck.<msg-id>` and `fetch.fsck.<msg-id>`
 will only cause git to warn.
++
+The following `<msg-id>` are supported:
++
+
+include::../fsck-msgids.txt[]
 
 fsck.skipList::
 	The path to a list of object names (i.e. one unabbreviated SHA-1 per
diff --git a/Documentation/fsck-msgids.txt b/Documentation/fsck-msgids.txt
new file mode 100644
index 00000000000..888fa3308b7
--- /dev/null
+++ b/Documentation/fsck-msgids.txt
@@ -0,0 +1,133 @@
+--
+`badDate`;;
+	Invalid date format in an author/committer line.
+
+`badEmail`;;
+	Invalid email format in an author/committer line.
+
+`badFilemode`;;
+	A tree contains a bad filemode entry.
+
+`badName`;;
+	An author/committer name is empty.
+
+`badObjectSha1`;;
+	An object has a bad sha1.
+
+`badParentSha1`;;
+	A commit object has a bad parent sha1.
+
+`badTagName`;;
+	A tag has an invalid format.
+
+`badTimezone`;;
+	Found an invalid time zone in an author/committer line.
+
+`badTree`;;
+	A tree cannot be parsed.
+
+`badTreeSha1`;;
+	A tree has an invalid format.
+
+`badType`;;
+	Found an invalid object type.
+
+`duplicateEntries`;;
+	A tree contains duplicate file entries.
+
+`emptyName`;;
+	A path contains an empty name.
+
+`fullPathName`;;
+	A path contains the full path starting with "/".
+
+`gitAttributesSymlink`;;
+	`.gitattributes` is a symlink.
+
+`gitignoreSymlink`;;
+	`.gitignore` is a symlink.
+
+`gitmodulesBlob`;;
+	A non-blob found at `.gitmodules`.
+
+`gitmodulesMissing`;;
+	Unable to read `.gitmodules` blob.
+
+`gitmodulesName`;;
+	A submodule name is invalid.
+
+`gitmodulesParse`;;
+	Could not parse `.gitmodules` blob.
+
+`gitmodulesLarge`;
+	`.gitmodules` blob is too large to parse.
+
+`gitmodulesPath`;;
+	`.gitmodules` path is invalid.
+
+`gitmodulesSymlink`;;
+	`.gitmodules` is a symlink.
+
+`gitmodulesUpdate`;;
+	Found an invalid submodule update setting.
+
+`gitmodulesUrl`;;
+	Found an invalid submodule url.
+
+`hasDot`;;
+	A tree contains an entry named `.`.
+
+`hasDotdot`;;
+	A tree contains an entry named `..`.
+
+`hasDotgit`;;
+	A tree contains an entry named `.git`.
+
+`mailmapSymlink`;;
+	`.mailmap` is a symlink.
+
+`missingAuthor`;;
+	Author is missing.
+
+`missingCommitter`;;
+	Committer is missing.
+
+`missingEmail`;;
+	Email is missing in an author/committer line.
+
+`missingNameBeforeEmail`;;
+	Missing space before an email in an author/committer line.
+
+`missingObject`;;
+	Missing `object` line in tag object.
+
+`missingSpaceBeforeDate`;;
+	Missing space before date in an author/committer line.
+
+`missingSpaceBeforeEmail`;;
+	Missing space before the email in author/committer line.
+
+`missingTag`;;
+	Unexpected end after `type` line in a tag object.
+
+`missingTypeEntry`;;
+	Missing `type` line in a tag object.
+
+`multipleAuthors`;;`
+	Multiple author lines found in a commit.
+
+`nulInCommit`;;
+	Found a NUL byte in the commit object body.
+
+`treeNotSorted`;;
+	A tree is not properly sorted.
+
+`unknownType`;;
+	Found an unknown object type.
+
+`zeroPaddingDate`;;
+	Found a zero padded date in an author/commiter line.
+
+`zeroPaddedFilemode`;;
+	Found a zero padded filemode in a tree.
+--
-- 
gitgitgadget
Previous: John Cai via GitGitGadgetNext: Junio C Hamano
Message 2 of 35 in “Document fsck msg ids”
  1. 0/2 Document fsck msg idsJohn Cai via GitGitGadget, Oct 24, 2022
  2. 2/2 fsck: document msg-idJohn Cai via GitGitGadget, Oct 24, 2022
  3. Junio C HamanoOct 24, 2022
  4. Ævar Arnfjörð BjarmasonOct 25, 2022
  5. Junio C HamanoOct 25, 2022
  6. 1/2 fsck: remove the unused BAD_TAG_OBJECTJohn Cai via GitGitGadget, Oct 24, 2022
  7. Junio C HamanoOct 24, 2022
  8. Junio C HamanoOct 24, 2022
  9. John CaiOct 24, 2022
  10. Jeff KingOct 24, 2022
  11. Junio C HamanoOct 24, 2022
  12. 0/2 Document fsck msg idsJohn Cai via GitGitGadget, Oct 25, 2022
  13. 1/2 fsck: remove the unused BAD_TAG_OBJECTJohn Cai via GitGitGadget, Oct 25, 2022
  14. 2/2 fsck: document msg-idJohn Cai via GitGitGadget, Oct 25, 2022
  15. Junio C HamanoOct 25, 2022
  16. Junio C HamanoOct 25, 2022
  17. Documentation: add lint-fsck-msgidsJunio C Hamano, Oct 25, 2022
  18. 0/4 document fsck error message idsJunio C Hamano, Oct 25, 2022
  19. 1/4 fsck: remove the unused BAD_TAG_OBJECTJunio C Hamano, Oct 25, 2022
  20. 2/4 fsck: remove the unused MISSING_TREE_OBJECTJunio C Hamano, Oct 25, 2022
  21. 3/4 fsck: document msg-idJunio C Hamano, Oct 25, 2022
  22. 4/4 Documentation: add lint-fsck-msgidsJunio C Hamano, Oct 25, 2022
  23. Ævar Arnfjörð BjarmasonOct 26, 2022
  24. Jeff KingOct 26, 2022
  25. Junio C HamanoOct 26, 2022
  26. Ævar Arnfjörð BjarmasonOct 26, 2022
  27. Jeff KingOct 28, 2022
  28. Ævar Arnfjörð BjarmasonOct 28, 2022
  29. Jeff KingOct 28, 2022
  30. Ævar Arnfjörð BjarmasonOct 28, 2022
  31. John CaiOct 28, 2022
  32. Ævar Arnfjörð BjarmasonOct 28, 2022
  33. Junio C HamanoOct 28, 2022
  34. Jeff KingOct 28, 2022
  35. Jeff KingOct 28, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.