Skip to content

Commit 8534bb4

Browse files
Martin Ågrengitster
authored andcommitted
git-cat-file.txt: fix list continuations rendering literally
With Asciidoctor, all of the '+' introduced in a797c0e ("cat-file: add mailmap support to --batch-check option", 2022-12-20) render literally rather than functioning as list continuations. With asciidoc, this renders just fine. It's not too surprising that there is room for ambiguity and surprises here, since we have lists within lists. Simply replacing all of these '+' with empty lines makes this render fine using both tools. Except, in the third hunk, where after this inner '*' list ends, we want to continue with more contents of the outer list item (`--batch-command=<format>`). We can solve any ambiguity here and make this clear to both tools by wrapping the inner list in an open block (using "--"). For consistency, let's wrap all three of these inner lists from a797c0e in open blocks. This also future-proofs us a little -- if we ever gain more contents after any of those first two lists, as we did already in a797c0e for the third list, we're prepared and should render fine with both asciidoc and Asciidoctor from the start. Signed-off-by: Martin Ågren <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent a797c0e commit 8534bb4

File tree

1 file changed

+12
-7
lines changed

1 file changed

+12
-7
lines changed

Documentation/git-cat-file.txt

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -93,47 +93,52 @@ OPTIONS
9393
Print object information and contents for each object provided
9494
on stdin. May not be combined with any other options or arguments
9595
except `--textconv`, `--filters`, or `--use-mailmap`.
96-
+
96+
+
97+
--
9798
* When used with `--textconv` or `--filters`, the input lines
9899
must specify the path, separated by whitespace. See the section
99100
`BATCH OUTPUT` below for details.
100-
+
101+
101102
* When used with `--use-mailmap`, for commit and tag objects, the
102103
contents part of the output shows the identities replaced using the
103104
mailmap mechanism, while the information part of the output shows
104105
the size of the object as if it actually recorded the replacement
105106
identities.
107+
--
106108

107109
--batch-check::
108110
--batch-check=<format>::
109111
Print object information for each object provided on stdin. May not be
110112
combined with any other options or arguments except `--textconv`, `--filters`
111113
or `--use-mailmap`.
112-
+
114+
+
115+
--
113116
* When used with `--textconv` or `--filters`, the input lines must
114117
specify the path, separated by whitespace. See the section
115118
`BATCH OUTPUT` below for details.
116-
+
119+
117120
* When used with `--use-mailmap`, for commit and tag objects, the
118121
printed object information shows the size of the object as if the
119122
identities recorded in it were replaced by the mailmap mechanism.
123+
--
120124

121125
--batch-command::
122126
--batch-command=<format>::
123127
Enter a command mode that reads commands and arguments from stdin. May
124128
only be combined with `--buffer`, `--textconv`, `--use-mailmap` or
125129
`--filters`.
126-
+
130+
+
131+
--
127132
* When used with `--textconv` or `--filters`, the input lines must
128133
specify the path, separated by whitespace. See the section
129134
`BATCH OUTPUT` below for details.
130-
+
135+
131136
* When used with `--use-mailmap`, for commit and tag objects, the
132137
`contents` command shows the identities replaced using the
133138
mailmap mechanism, while the `info` command shows the size
134139
of the object as if it actually recorded the replacement
135140
identities.
136-
141+
--
137142
+
138143
`--batch-command` recognizes the following commands:
139144
+

0 commit comments

Comments
 (0)