Skip to content

Commit 23f8239

Browse files
moygitster
authored andcommitted
doc: typeset short command-line options as literal
It was common in our documentation to surround short option names with forward quotes, which renders as italic in HTML. Instead, use backquotes which renders as monospace. This is one more step toward conformance to Documentation/CodingGuidelines. This was obtained with: perl -pi -e "s/'(-[a-z])'/\`\$1\`/g" *.txt Signed-off-by: Matthieu Moy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 46e22b7 commit 23f8239

23 files changed

+52
-52
lines changed

Documentation/config.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -913,7 +913,7 @@ browser.<tool>.cmd::
913913

914914
browser.<tool>.path::
915915
Override the path for the given tool that may be used to
916-
browse HTML help (see '-w' option in linkgit:git-help[1]) or a
916+
browse HTML help (see `-w` option in linkgit:git-help[1]) or a
917917
working repository in gitweb (see linkgit:git-instaweb[1]).
918918

919919
clean.requireForce::
@@ -1394,9 +1394,9 @@ gitcvs.logFile::
13941394

13951395
gitcvs.usecrlfattr::
13961396
If true, the server will look up the end-of-line conversion
1397-
attributes for files to determine the '-k' modes to use. If
1397+
attributes for files to determine the `-k` modes to use. If
13981398
the attributes force Git to treat a file as text,
1399-
the '-k' mode will be left blank so CVS clients will
1399+
the `-k` mode will be left blank so CVS clients will
14001400
treat it as text. If they suppress text conversion, the file
14011401
will be set with '-kb' mode, which suppresses any newline munging
14021402
the client might otherwise do. If the attributes do not allow
@@ -1466,7 +1466,7 @@ gitweb.snapshot::
14661466
See linkgit:gitweb.conf[5] for description.
14671467

14681468
grep.lineNumber::
1469-
If set to true, enable '-n' option by default.
1469+
If set to true, enable `-n` option by default.
14701470

14711471
grep.patternType::
14721472
Set the default matching behavior. Using a value of 'basic', 'extended',

Documentation/diff-config.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ diff.orderFile::
105105

106106
diff.renameLimit::
107107
The number of files to consider when performing the copy/rename
108-
detection; equivalent to the 'git diff' option '-l'.
108+
detection; equivalent to the 'git diff' option `-l`.
109109

110110
diff.renames::
111111
Tells Git to detect renames. If set to any boolean value, it

Documentation/diff-format.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,11 +46,11 @@ That is, from the left to the right:
4646
. sha1 for "dst"; 0\{40\} if creation, unmerged or "look at work tree".
4747
. a space.
4848
. status, followed by optional "score" number.
49-
. a tab or a NUL when '-z' option is used.
49+
. a tab or a NUL when `-z` option is used.
5050
. path for "src"
51-
. a tab or a NUL when '-z' option is used; only exists for C or R.
51+
. a tab or a NUL when `-z` option is used; only exists for C or R.
5252
. path for "dst"; only exists for C or R.
53-
. an LF or a NUL when '-z' option is used, to terminate the record.
53+
. an LF or a NUL when `-z` option is used, to terminate the record.
5454

5555
Possible status letters are:
5656

@@ -86,7 +86,7 @@ diff format for merges
8686
----------------------
8787

8888
"git-diff-tree", "git-diff-files" and "git-diff --raw"
89-
can take '-c' or '--cc' option
89+
can take `-c` or '--cc' option
9090
to generate diff output also for merge commits. The output differs
9191
from the format described above in the following way:
9292

Documentation/diff-generate-patch.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Generating patches with -p
22
--------------------------
33

44
When "git-diff-index", "git-diff-tree", or "git-diff-files" are run
5-
with a '-p' option, "git diff" without the '--raw' option, or
5+
with a `-p` option, "git diff" without the '--raw' option, or
66
"git log" with the "-p" option, they
77
do not produce the output described above; instead they produce a
88
patch file. You can customize the creation of such patches via the
@@ -114,7 +114,7 @@ index fabadb8,cc95eb0..4866510
114114
------------
115115

116116
1. It is preceded with a "git diff" header, that looks like
117-
this (when '-c' option is used):
117+
this (when `-c` option is used):
118118

119119
diff --combined file
120120
+

Documentation/git-cat-file.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ SYNOPSIS
1515
DESCRIPTION
1616
-----------
1717
In its first form, the command provides the content or the type of an object in
18-
the repository. The type is required unless '-t' or '-p' is used to find the
19-
object type, or '-s' is used to find the object size, or '--textconv' is used
18+
the repository. The type is required unless `-t` or `-p` is used to find the
19+
object type, or `-s` is used to find the object size, or '--textconv' is used
2020
(which implies type "blob").
2121

2222
In the second form, a list of objects (separated by linefeeds) is provided on
@@ -144,13 +144,13 @@ respectively print:
144144

145145
OUTPUT
146146
------
147-
If '-t' is specified, one of the <type>.
147+
If `-t` is specified, one of the <type>.
148148

149-
If '-s' is specified, the size of the <object> in bytes.
149+
If `-s` is specified, the size of the <object> in bytes.
150150

151-
If '-e' is specified, no output.
151+
If `-e` is specified, no output.
152152

153-
If '-p' is specified, the contents of <object> are pretty-printed.
153+
If `-p` is specified, the contents of <object> are pretty-printed.
154154

155155
If <type> is specified, the raw (though uncompressed) contents of the <object>
156156
will be returned.

Documentation/git-checkout.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,15 +157,15 @@ of it").
157157
When creating a new branch, set up "upstream" configuration. See
158158
"--track" in linkgit:git-branch[1] for details.
159159
+
160-
If no '-b' option is given, the name of the new branch will be
160+
If no `-b` option is given, the name of the new branch will be
161161
derived from the remote-tracking branch, by looking at the local part of
162162
the refspec configured for the corresponding remote, and then stripping
163163
the initial part up to the "*".
164164
This would tell us to use "hack" as the local branch when branching
165165
off of "origin/hack" (or "remotes/origin/hack", or even
166166
"refs/remotes/origin/hack"). If the given name has no slash, or the above
167167
guessing results in an empty name, the guessing is aborted. You can
168-
explicitly give a name with '-b' in such a case.
168+
explicitly give a name with `-b` in such a case.
169169

170170
--no-track::
171171
Do not set up "upstream" configuration, even if the

Documentation/git-clean.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ DESCRIPTION
1616
Cleans the working tree by recursively removing files that are not
1717
under version control, starting from the current directory.
1818

19-
Normally, only files unknown to Git are removed, but if the '-x'
19+
Normally, only files unknown to Git are removed, but if the `-x`
2020
option is specified, ignored files are also removed. This can, for
2121
example, be useful to remove all build products.
2222

Documentation/git-commit-tree.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ OPTIONS
4444
An existing tree object
4545

4646
-p <parent>::
47-
Each '-p' indicates the id of a parent commit object.
47+
Each `-p` indicates the id of a parent commit object.
4848

4949
-m <message>::
5050
A paragraph in the commit log message. This can be given more than

Documentation/git-commit.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ OPTIONS
7575

7676
-c <commit>::
7777
--reedit-message=<commit>::
78-
Like '-C', but with '-c' the editor is invoked, so that
78+
Like '-C', but with `-c` the editor is invoked, so that
7979
the user can further edit the commit message.
8080

8181
--fixup=<commit>::

Documentation/git-cvsimport.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ the old cvs2git tool.
103103

104104
-p <options-for-cvsps>::
105105
Additional options for cvsps.
106-
The options '-u' and '-A' are implicit and should not be used here.
106+
The options `-u` and '-A' are implicit and should not be used here.
107107
+
108108
If you need to pass multiple options, separate them with a comma.
109109

@@ -122,7 +122,7 @@ If you need to pass multiple options, separate them with a comma.
122122

123123
-M <regex>::
124124
Attempt to detect merges based on the commit message with a custom
125-
regex. It can be used with '-m' to enable the default regexes
125+
regex. It can be used with `-m` to enable the default regexes
126126
as well. You must escape forward slashes.
127127
+
128128
The regex must capture the source branch name in $1.
@@ -186,7 +186,7 @@ messages, bug-tracking systems, email archives, and the like.
186186

187187
OUTPUT
188188
------
189-
If '-v' is specified, the script reports what it is doing.
189+
If `-v` is specified, the script reports what it is doing.
190190

191191
Otherwise, success is indicated the Unix way, i.e. by simply exiting with
192192
a zero exit status.

0 commit comments

Comments
 (0)