From: "Martin Ågren" <martin.agren@gmail.com>
To: git@vger.kernel.org
Subject: [PATCH 4/6] diff-options.txt: move monospace markup out of attribute
Date: Thu, 13 May 2021 20:17:43 +0200 [thread overview]
Message-ID: <f6241315a4d90185882a247d1c81ed7ee595d9a9.1620928059.git.martin.agren@gmail.com> (raw)
In-Reply-To: <cover.1620928059.git.martin.agren@gmail.com>
git-log.txt and git-show.txt want to use different defaults for the
`--no-diff-merges` option. They do this by defining a
"diff-merges-default" attribute as, e.g., `off` (with backticks), which
is then referenced in the common diff-options.txt.
AsciiDoc renders the default in monospace, as wanted, but Asciidoctor
renders the backticks literally.
Pull the formatting into diff-options.txt and define
"diff-merges-default" without any quotation or markup. We can't write
`{diff-merges-default)` with backticks since that would render as
"{diff-merges-default}", but we can use +{diff-merges-default}+ -- both
Asciidoc and Asciidoctor do the substitution and the parsing of the
plusses in the order we want.
Signed-off-by: Martin Ågren <martin.agren@gmail.com>
---
Documentation/diff-options.txt | 2 +-
Documentation/git-log.txt | 2 +-
Documentation/git-show.txt | 2 +-
3 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/Documentation/diff-options.txt b/Documentation/diff-options.txt
index 530d115914..6eb8bfff5d 100644
--- a/Documentation/diff-options.txt
+++ b/Documentation/diff-options.txt
@@ -37,7 +37,7 @@ ifdef::git-log[]
--diff-merges=(off|none|on|first-parent|1|separate|m|combined|c|dense-combined|cc)::
--no-diff-merges::
Specify diff format to be used for merge commits. Default is
- {diff-merges-default} unless `--first-parent` is in use, in which case
+ +{diff-merges-default}+ unless `--first-parent` is in use, in which case
`first-parent` is the default.
+
--diff-merges=(off|none):::
diff --git a/Documentation/git-log.txt b/Documentation/git-log.txt
index 1bbf865a1b..19560650bf 100644
--- a/Documentation/git-log.txt
+++ b/Documentation/git-log.txt
@@ -115,7 +115,7 @@ is when `--first-parent` is in use, in which case `first-parent` is
the default format.
:git-log: 1
-:diff-merges-default: `off`
+:diff-merges-default: off
include::diff-options.txt[]
include::diff-generate-patch.txt[]
diff --git a/Documentation/git-show.txt b/Documentation/git-show.txt
index 2b1bc7288d..f8341e51c0 100644
--- a/Documentation/git-show.txt
+++ b/Documentation/git-show.txt
@@ -51,7 +51,7 @@ The options below can be used to change the way `git show` generates
diff output.
:git-log: 1
-:diff-merges-default: `dense-combined`
+:diff-merges-default: dense-combined
include::diff-options.txt[]
include::diff-generate-patch.txt[]
--
2.31.1.751.gd2f1c929bd
next prev parent reply other threads:[~2021-05-13 18:18 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-13 18:17 [PATCH 0/6] AsciiDoc vs Asciidoctor, once again Martin Ågren
2021-05-13 18:17 ` [PATCH 1/6] git-http-push.txt,git-send-pack.txt: avoid single quote Martin Ågren
2021-05-13 18:17 ` [PATCH 2/6] git-range-diff.txt: avoid single quotes Martin Ågren
2021-05-13 18:17 ` [PATCH 3/6] git-check-ref-format.txt: avoid single quote Martin Ågren
2021-05-13 19:16 ` Eric Sunshine
2021-05-13 19:35 ` Martin Ågren
2021-05-13 22:00 ` Junio C Hamano
2021-05-14 9:07 ` Martin Ågren
2021-05-14 12:30 ` Felipe Contreras
2021-05-14 5:30 ` Jeff King
2021-05-14 9:08 ` Martin Ågren
2021-05-13 18:17 ` Martin Ågren [this message]
2021-05-13 18:17 ` [PATCH 5/6] git-svn.txt: change verse to listing block Martin Ågren
2021-05-13 18:17 ` [PATCH 6/6] Doc: use two backticks for monospace, not backtick+apostrophe Martin Ågren
2021-05-13 20:35 ` [PATCH 0/6] AsciiDoc vs Asciidoctor, once again Junio C Hamano
2021-05-14 8:40 ` Martin Ågren
2021-05-14 12:18 ` Felipe Contreras
2021-05-14 1:40 ` Felipe Contreras
2021-05-14 8:43 ` Martin Ågren
2021-05-14 12:24 ` Felipe Contreras
2021-05-14 15:28 ` Martin Ågren
2021-05-14 20:11 ` Felipe Contreras
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=f6241315a4d90185882a247d1c81ed7ee595d9a9.1620928059.git.martin.agren@gmail.com \
--to=martin.agren@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).