doc: am: normalize git(1) command links

There are many mentions of commands using inline-verbatim or emphasis ('). We just mention the command themselves, not specific invocations like `git am <opts>`. Let’s link to them instead. There are also many such mentions which then link to the command right afterwards. Simplify to just using a link. Also remove “see <gitlink>” phrases where they have now already been mentioned. Signed-off-by: Kristoffer Haugsbakk <code@khaugsbakk.name> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Kristoffer Haugsbakk committed Feb 9, 2026 at 18:34 UTC b679ee04226f4ba1633078797f3aa3a5677e2c5c
2 files changed +24 -25
Documentation/config/am.adoc
+9 -9
@@ -1,14 +1,14 @@
1 am.keepcr::
2 - If true, git-am will call git-mailsplit for patches in mbox format
3 - with parameter `--keep-cr`. In this case git-mailsplit will
2 + If true, linkgit:git-am[1] will call linkgit:git-mailsplit[1]
3 + for patches in mbox format with parameter `--keep-cr`. In this
4 + case linkgit:git-mailsplit[1] will
5 not remove `\r` from lines ending with `\r\n`. Can be overridden
6 by giving `--no-keep-cr` from the command line.
6 - See linkgit:git-am[1], linkgit:git-mailsplit[1].
7
8 am.threeWay::
9 - By default, `git am` will fail if the patch does not apply cleanly. When
10 - set to true, this setting tells `git am` to fall back on 3-way merge if
11 - the patch records the identity of blobs it is supposed to apply to and
12 - we have those blobs available locally (equivalent to giving the `--3way`
13 - option from the command line). Defaults to `false`.
14 - See linkgit:git-am[1].
9 + By default, linkgit:git-am[1] will fail if the patch does not
10 + apply cleanly. When set to true, this setting tells
11 + linkgit:git-am[1] to fall back on 3-way merge if the patch
12 + records the identity of blobs it is supposed to apply to and we
13 + have those blobs available locally (equivalent to giving the
14 + `--3way` option from the command line). Defaults to `false`.
Documentation/git-am.adoc
+15 -16
@@ -43,14 +43,14 @@ OPTIONS
43
44 -k::
45 --keep::
46 - Pass `-k` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]).
46 + Pass `-k` flag to linkgit:git-mailinfo[1].
47
48 --keep-non-patch::
49 - Pass `-b` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]).
49 + Pass `-b` flag to linkgit:git-mailinfo[1].
50
51 --keep-cr::
52 --no-keep-cr::
53 - With `--keep-cr`, call 'git mailsplit' (see linkgit:git-mailsplit[1])
53 + With `--keep-cr`, call linkgit:git-mailsplit[1]
54 with the same option, to prevent it from stripping CR at the end of
55 lines. `am.keepcr` configuration variable can be used to specify the
56 default behaviour. `--no-keep-cr` is useful to override `am.keepcr`.
@@ -65,7 +65,7 @@ OPTIONS
65 Ignore scissors lines (see linkgit:git-mailinfo[1]).
66
67 --quoted-cr=<action>::
68 - This flag will be passed down to 'git mailinfo' (see linkgit:git-mailinfo[1]).
68 + This flag will be passed down to linkgit:git-mailinfo[1].
69
70 --empty=(drop|keep|stop)::
71 How to handle an e-mail message lacking a patch:
@@ -83,7 +83,7 @@ OPTIONS
83
84 -m::
85 --message-id::
86 - Pass the `-m` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]),
86 + Pass the `-m` flag to linkgit:git-mailinfo[1],
87 so that the Message-ID header is added to the commit message.
88 The `am.messageid` configuration variable can be used to specify
89 the default behaviour.
@@ -98,7 +98,7 @@ OPTIONS
98
99 -u::
100 --utf8::
101 - Pass `-u` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]).
101 + Pass `-u` flag to linkgit:git-mailinfo[1].
102 The proposed commit log message taken from the e-mail
103 is re-coded into UTF-8 encoding (configuration variable
104 `i18n.commitEncoding` can be used to specify the project's
@@ -108,8 +108,7 @@ This was optional in prior versions of git, but now it is the
108 default. You can use `--no-utf8` to override this.
109
110 --no-utf8::
111 - Pass `-n` flag to 'git mailinfo' (see
112 - linkgit:git-mailinfo[1]).
111 + Pass `-n` flag to linkgit:git-mailinfo[1].
112
113 -3::
114 --3way::
@@ -132,9 +131,8 @@ include::rerere-options.adoc[]
131 --exclude=<path>::
132 --include=<path>::
133 --reject::
135 - These flags are passed to the 'git apply' (see linkgit:git-apply[1])
136 - program that applies
137 - the patch.
134 + These flags are passed to the linkgit:git-apply[1] program that
135 + applies the patch.
136 +
137 Valid <action> for the `--whitespace` option are:
138 `nowarn`, `warn`, `fix`, `error`, and `error-all`.
@@ -198,7 +196,8 @@ Valid <action> for the `--whitespace` option are:
196 to the screen before exiting. This overrides the
197 standard message informing you to use `--continue`
198 or `--skip` to handle the failure. This is solely
201 - for internal use between 'git rebase' and 'git am'.
199 + for internal use between linkgit:git-rebase[1] and
200 + linkgit:git-am[1].
201
202 --abort::
203 Restore the original branch and abort the patching operation.
@@ -216,7 +215,7 @@ Valid <action> for the `--whitespace` option are:
215 failure again.
216
217 --show-current-patch[=(diff|raw)]::
219 - Show the message at which `git am` has stopped due to
218 + Show the message at which linkgit:git-am[1] has stopped due to
219 conflicts. If `raw` is specified, show the raw contents of
220 the e-mail message; if `diff`, show the diff portion only.
221 Defaults to `raw`.
@@ -254,7 +253,7 @@ message. Any line that is of the form:
253 is taken as the beginning of a patch, and the commit log message
254 is terminated before the first occurrence of such a line.
255
257 -When initially invoking `git am`, you give it the names of the mailboxes
256 +When initially invoking linkgit:git-am[1], you give it the names of the mailboxes
257 to process. Upon seeing the first patch that does not apply, it
258 aborts in the middle. You can recover from this in one of two ways:
259
@@ -272,8 +271,8 @@ names.
271
272 Before any patches are applied, ORIG_HEAD is set to the tip of the
273 current branch. This is useful if you have problems with multiple
275 -commits, like running 'git am' on the wrong branch or an error in the
276 -commits that is more easily fixed by changing the mailbox (e.g.
274 +commits, like running linkgit:git-am[1] on the wrong branch or an error
275 +in the commits that is more easily fixed by changing the mailbox (e.g.
276 errors in the "From:" lines).
277
278 HOOKS