Skip to content

Commit 9f9ce43

Browse files
committed
doc: git-log: convert diff options to new doc format
- Use `backticks` for keywords and more complex option descriptions. The new rendering engine will apply synopsis rules to these spans. - In description lists, put each option on its own line, to make them more searchable and enable automatic translation of the options. Signed-off-by: Jean-Noël Avila <[email protected]>
1 parent d54e297 commit 9f9ce43

File tree

1 file changed

+23
-17
lines changed

1 file changed

+23
-17
lines changed

Documentation/diff-options.adoc

Lines changed: 23 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -37,81 +37,87 @@ endif::git-diff[]
3737
endif::git-format-patch[]
3838

3939
ifdef::git-log[]
40-
-m::
40+
`-m`::
4141
Show diffs for merge commits in the default format. This is
4242
similar to `--diff-merges=on`, except `-m` will
4343
produce no output unless `-p` is given as well.
4444

45-
-c::
45+
`-c`::
4646
Produce combined diff output for merge commits.
4747
Shortcut for `--diff-merges=combined -p`.
4848

49-
--cc::
49+
`--cc`::
5050
Produce dense combined diff output for merge commits.
5151
Shortcut for `--diff-merges=dense-combined -p`.
5252

53-
--dd::
53+
`--dd`::
5454
Produce diff with respect to first parent for both merge and
5555
regular commits.
5656
Shortcut for `--diff-merges=first-parent -p`.
5757

58-
--remerge-diff::
58+
`--remerge-diff`::
5959
Produce remerge-diff output for merge commits.
6060
Shortcut for `--diff-merges=remerge -p`.
6161

62-
--no-diff-merges::
62+
`--no-diff-merges`::
6363
Synonym for `--diff-merges=off`.
6464

65-
--diff-merges=<format>::
65+
`--diff-merges=<format>`::
6666
Specify diff format to be used for merge commits. Default is
6767
{diff-merges-default} unless `--first-parent` is in use, in
6868
which case `first-parent` is the default.
6969
+
7070
The following formats are supported:
7171
+
7272
--
73-
off, none::
73+
`off`::
74+
`none`::
7475
Disable output of diffs for merge commits. Useful to override
7576
implied value.
7677

77-
on, m::
78+
`on`::
79+
`m`::
7880
Make diff output for merge commits to be shown in the default
7981
format. The default format can be changed using
8082
`log.diffMerges` configuration variable, whose default value
8183
is `separate`.
8284

83-
first-parent, 1::
85+
`first-parent`::
86+
`1`::
8487
Show full diff with respect to first parent. This is the same
8588
format as `--patch` produces for non-merge commits.
8689

87-
separate::
90+
`separate`::
8891
Show full diff with respect to each of parents.
8992
Separate log entry and diff is generated for each parent.
9093

91-
combined, c::
94+
`combined`::
95+
`c`::
9296
Show differences from each of the parents to the merge
9397
result simultaneously instead of showing pairwise diff between
9498
a parent and the result one at a time. Furthermore, it lists
9599
only files which were modified from all parents.
96100

97-
dense-combined, cc::
101+
`dense-combined`::
102+
`cc`::
98103
Further compress output produced by `--diff-merges=combined`
99104
by omitting uninteresting hunks whose contents in the parents
100105
have only two variants and the merge result picks one of them
101106
without modification.
102107

103-
remerge, r::
104-
Remerge two-parent merge commits to create a temporary tree
108+
`remerge`::
109+
`r`:: Remerge two-parent merge commits to create a temporary tree
105110
object--potentially containing files with conflict markers
106111
and such. A diff is then shown between that temporary tree
107112
and the actual merge commit.
113+
--
108114
+
109115
The output emitted when this option is used is subject to change, and
110116
so is its interaction with other options (unless explicitly
111117
documented).
112-
--
113118

114-
--combined-all-paths::
119+
120+
`--combined-all-paths`::
115121
Cause combined diffs (used for merge commits) to
116122
list the name of the file from all parents. It thus only has
117123
effect when `--diff-merges=[dense-]combined` is in use, and

0 commit comments

Comments
 (0)