Documentation/git-reflog: convert to use synopsis type

With 974cdca345c (doc: introduce a synopsis typesetting, 2024-09-24) we have introduced a new synopsis type that simplifies the rules for typesetting a command's synopsis. Convert the git-reflog(1) documentation to use it. While at it, convert the list of options to use backticks. This is done to appease an upcoming new linter that mandates the use of backticks when using the synopsis type. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Patrick Steinhardt committed Aug 6, 2025 at 07:54 UTC e9493c55af074fb7179922fafa61104332c05cc9
1 file changed +19 -19
Documentation/git-reflog.adoc
+19 -19
@@ -8,16 +8,16 @@ git-reflog - Manage reflog information
8
9 SYNOPSIS
10 --------
11 -[verse]
12 -'git reflog' [show] [<log-options>] [<ref>]
13 -'git reflog list'
14 -'git reflog expire' [--expire=<time>] [--expire-unreachable=<time>]
11 +[synopsis]
12 +git reflog [show] [<log-options>] [<ref>]
13 +git reflog list
14 +git reflog expire [--expire=<time>] [--expire-unreachable=<time>]
15 [--rewrite] [--updateref] [--stale-fix]
16 [--dry-run | -n] [--verbose] [--all [--single-worktree] | <refs>...]
17 -'git reflog delete' [--rewrite] [--updateref]
17 +git reflog delete [--rewrite] [--updateref]
18 [--dry-run | -n] [--verbose] <ref>@{<specifier>}...
19 -'git reflog drop' [--all [--single-worktree] | <refs>...]
20 -'git reflog exists' <ref>
19 +git reflog drop [--all [--single-worktree] | <refs>...]
20 +git reflog exists <ref>
21
22 DESCRIPTION
23 -----------
@@ -74,15 +74,15 @@ Options for `show`
74 Options for `expire`
75 ~~~~~~~~~~~~~~~~~~~~
76
77 ---all::
77 +`--all`::
78 Process the reflogs of all references.
79
80 ---single-worktree::
80 +`--single-worktree`::
81 By default when `--all` is specified, reflogs from all working
82 trees are processed. This option limits the processing to reflogs
83 from the current working tree only.
84
85 ---expire=<time>::
85 +`--expire=<time>`::
86 Prune entries older than the specified time. If this option is
87 not specified, the expiration time is taken from the
88 configuration setting `gc.reflogExpire`, which in turn
@@ -90,7 +90,7 @@ Options for `expire`
90 of their age; `--expire=never` turns off pruning of reachable
91 entries (but see `--expire-unreachable`).
92
93 ---expire-unreachable=<time>::
93 +`--expire-unreachable=<time>`::
94 Prune entries older than `<time>` that are not reachable from
95 the current tip of the branch. If this option is not
96 specified, the expiration time is taken from the configuration
@@ -100,17 +100,17 @@ Options for `expire`
100 turns off early pruning of unreachable entries (but see
101 `--expire`).
102
103 ---updateref::
103 +`--updateref`::
104 Update the reference to the value of the top reflog entry (i.e.
105 <ref>@\{0\}) if the previous top entry was pruned. (This
106 option is ignored for symbolic references.)
107
108 ---rewrite::
108 +`--rewrite`::
109 If a reflog entry's predecessor is pruned, adjust its "old"
110 SHA-1 to be equal to the "new" SHA-1 field of the entry that
111 now precedes it.
112
113 ---stale-fix::
113 +`--stale-fix`::
114 Prune any reflog entries that point to "broken commits". A
115 broken commit is a commit that is not reachable from any of
116 the reference tips and that refers, directly or indirectly, to
@@ -121,12 +121,12 @@ has the same cost as 'git prune'. It is primarily intended to fix
121 corruption caused by garbage collecting using older versions of Git,
122 which didn't protect objects referred to by reflogs.
123
124 --n::
125 ---dry-run::
124 +`-n`::
125 +`--dry-run`::
126 Do not actually prune any entries; just show what would have
127 been pruned.
128
129 ---verbose::
129 +`--verbose`::
130 Print extra information on screen.
131
132
@@ -140,10 +140,10 @@ used with `expire`.
140 Options for `drop`
141 ~~~~~~~~~~~~~~~~~~
142
143 ---all::
143 +`--all`::
144 Drop the reflogs of all references from all worktrees.
145
146 ---single-worktree::
146 +`--single-worktree`::
147 By default when `--all` is specified, reflogs from all working
148 trees are dropped. This option limits the processing to reflogs
149 from the current working tree only.