Compare

cee3798cb4a54f1011ce0bcd36d47b79dafbb894..995251109fa3e631e6fc7204e8cad128e8da2217

doc/refs: backtick-quote commands and options consistently

The git-refs doc was converted to the synopsis style in 89be7d2774
(builtin/refs: add '--no-reflog' flag to drop reflogs, 2025-02-21).  The
commands and options were not backtick-quoted at that time.  84f3d6e11e
(doc lint: check that synopsis manpages have synopsis inlines,
2025-08-11) applied backtick-quotes to the existing commands and
options.

Subsequently, a number of commands and options were added without such
quoting, leaving the documentation rendered inconsistently.  Apply
backtick-quotes to all entries.

Signed-off-by: Todd Zullinger <tmz@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>

Todd Zullinger <tmz@pobox.com> · 2026-09-15 13:10 UTC · committed by Junio C Hamano

Browse files
5 files changed, +18 −19
modified Documentation/config/maintenance.adoc
@@ -41,7 +41,6 @@ The possible strategies are:
41 41 This repacking strategy is a full replacement for the `gc` strategy and is
42 42 recommended for large repositories. This is the default strategy for manual
43 43 maintenance.
44 - +
45 44 * `incremental`: This setting optimizes for performing small maintenance
46 45 activities that do not delete any data. This does not schedule the `gc`
47 46 task, but runs the `prefetch` and `commit-graph` tasks hourly, the
modified Documentation/git-pack-refs.adoc
@@ -7,8 +7,8 @@ git-pack-refs - Pack heads and tags for efficient repository access
7 7
8 8 SYNOPSIS
9 9 --------
10 - [verse]
11 - 'git pack-refs' [--all] [--no-prune] [--auto] [--include <pattern>] [--exclude <pattern>]
10 + [synopsis]
11 + git pack-refs [--all] [--no-prune] [--auto] [--include <pattern>] [--exclude <pattern>]
12 12
13 13 DESCRIPTION
14 14 -----------
@@ -52,8 +52,8 @@ BUGS
52 52 ----
53 53
54 54 Older documentation written before the packed-refs mechanism was
55 - introduced may still say things like ".git/refs/heads/<branch> file
56 - exists" when it means "branch <branch> exists".
55 + introduced may still say things like ".git/refs/heads/_<branch>_ file
56 + exists" when it means "branch _<branch>_ exists".
57 57
58 58
59 59 GIT
modified Documentation/git-refs.adoc
@@ -54,40 +54,40 @@ These limitations may eventually be lifted.
54 54 `verify`::
55 55 Verify reference database consistency.
56 56
57 - list::
57 + `list`::
58 58 List references in the repository with support for filtering,
59 59 formatting, and sorting. This subcommand is an alias for
60 60 linkgit:git-for-each-ref[1] and offers identical functionality.
61 61
62 - exists::
62 + `exists`::
63 63 Check whether the given reference exists. Returns an exit code of 0 if
64 64 it does, 2 if it is missing, and 1 in case looking up the reference
65 65 failed with an error other than the reference being missing. This does
66 66 not verify whether the reference resolves to an actual object.
67 67
68 - optimize::
68 + `optimize`::
69 69 Optimizes references to improve repository performance and reduce disk
70 70 usage. This subcommand is an alias for linkgit:git-pack-refs[1] and
71 71 offers identical functionality.
72 72
73 - create::
73 + `create`::
74 74 Create the given reference, which must not already exist, pointing at
75 75 `<new-value>`.
76 76
77 - delete::
77 + `delete`::
78 78 Delete the given reference. This subcommand mirrors `git update-ref -d`
79 79 (see linkgit:git-update-ref[1]). When `<old-value>` is given, the
80 80 reference is only deleted after verifying that it currently contains
81 81 `<old-value>`.
82 82
83 - update::
83 + `update`::
84 84 Update the given reference to point at `<new-value>`. If `<old-value>`
85 85 is given, the reference is only updated after verifying that it
86 86 currently contains `<old-value>`. As a special case, an all-zeroes
87 87 `<new-value>` deletes the branch, whereas an all-zeroes `<old-value>`
88 88 ensures that the branch does not yet exist.
89 89
90 - rename::
90 + `rename`::
91 91 Rename the reference `<oldref>` to `<newref>`. The old reference must
92 92 exist and the new reference must not yet exist, and both must have a
93 93 well-formed name (see linkgit:git-check-ref-format[1]).
modified Documentation/pack-refs-options.adoc
@@ -1,4 +1,4 @@
1 - --all::
1 + `--all`::
2 2
3 3 The command by default packs all tags and refs that are already
4 4 packed, and leaves other refs
@@ -8,12 +8,12 @@ This option causes all refs to be packed as well, with the exception
8 8 of hidden refs, broken refs, and symbolic refs. Useful for a repository
9 9 with many branches of historical interests.
10 10
11 - --no-prune::
11 + `--no-prune`::
12 12
13 13 The command usually removes loose refs under `$GIT_DIR/refs`
14 14 hierarchy after packing them. This option tells it not to.
15 15
16 - --auto::
16 + `--auto`::
17 17
18 18 Pack refs as needed depending on the current state of the ref database. The
19 19 behavior depends on the ref format used by the repository and may change in the
@@ -29,7 +29,7 @@ future.
29 29 maintains the property that N is at least twice as big as N+1. Only
30 30 tables that violate this property are compacted.
31 31
32 - --include <pattern>::
32 + `--include <pattern>`::
33 33
34 34 Pack refs based on a `glob(7)` pattern. Repetitions of this option
35 35 accumulate inclusion patterns. If a ref is both included in `--include` and
@@ -38,7 +38,7 @@ tags from being included by default. Symbolic refs and broken refs will never
38 38 be packed. When used with `--all`, it will be a noop. Use `--no-include` to clear
39 39 and reset the list of patterns.
40 40
41 - --exclude <pattern>::
41 + `--exclude <pattern>`::
42 42
43 43 Do not pack refs matching the given `glob(7)` pattern. Repetitions of this option
44 44 accumulate exclusion patterns. Use `--no-exclude` to clear and reset the list of
modified ci/install-dependencies.sh
@@ -164,9 +164,9 @@ sparse)
164 164 libexpat-dev gettext zlib1g-dev sparse
165 165 ;;
166 166 Documentation)
167 - sudo apt-get -q -y install asciidoc xmlto docbook-xsl-ns make ruby \
168 - asciidoctor
167 + sudo apt-get -q -y install asciidoc xmlto docbook-xsl-ns make ruby
169 168
169 + sudo gem install --version 1.5.8 asciidoctor
170 170 sudo gem install concurrent-ruby
171 171 ;;
172 172 esac