From: Junio C Hamano <gitster@pobox.com>
To: git@vger.kernel.org
Cc: "Avery Pennarun" <apenwarr@gmail.com>,
"Thomas Rast" <trast@student.ethz.ch>
Subject: Re: [PATCH] Documentation: replace [^~] with escapes everywhere
Date: Tue, 16 Sep 2008 09:48:10 -0700 [thread overview]
Message-ID: <7vhc8g6nqt.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: <32541b130809160858k3c019f6pdc4831c831e22b55@mail.gmail.com> (Avery Pennarun's message of "Tue, 16 Sep 2008 11:58:58 -0400")
"Avery Pennarun" <apenwarr@gmail.com> writes:
> Hmm, browsing around through a newer asciidoc package from Ubuntu, it
> appears that in asciidoc 8, those lines are in an
> "ifdef::asciidoc7compatible[]" section. But the quoting mechanism in
> 8 appears to be improved.
>
> Perhaps a section like this (guessing from the new
> /etc/asciidoc/asciidoc.conf) will do the job instead (or in addition,
> if we're trying to support both versions):
>
> [quotes]
> ^=
> ~=
Ok, how about this patch? I do not have an access to the box with
AsciiDoc 8 handy right now, so I cannot test this myself, but there must
be somebody on the list who can give a quick test to this.
The procedure would be:
$ cd Documentation
$ rm -fr ./+old ./+new && mkdir ./+old ./+new
$ make git-{bundle,show-ref}.{html,1}
$ mv git-{bundle,show-ref}.{html,1} ./+old
$ git apply < this-patch
$ make git-{bundle,show-ref}.{html,1}
$ mv git-{bundle,show-ref}.{html,1} ./+new
$ git diff --no-index --color-words ./+old ./+new
Then eyeball the output, ignoring the timestamps and see if <sup>/<sub>
disappears and there is no other change. Other documentation pages should
also be verified, but these two are I know of with the issue.
diff --git i/Documentation/asciidoc.conf w/Documentation/asciidoc.conf
index 40d43b7..36b6509 100644
--- i/Documentation/asciidoc.conf
+++ w/Documentation/asciidoc.conf
@@ -15,6 +15,21 @@ startsb=[
endsb=]
tilde=~
+[replacements]
+# Disable superscripts.
+\^(.+?)\^=^\1^
+# Disable subscripts.
+~(.+?)~=~\1~
+
+# We define asciidoc7compatible macro when running with AsciiDoc 8;
+# this ifdef protects the "empty" quotes rule that AsciiDoc 7 does
+# not know how to handle.
+ifdef::asciidoc7compatible[]
+[quotes]
+^=
+~=
+endif::asciidoc7compatible[]
+
ifdef::backend-docbook[]
[linkgit-inlinemacro]
{0%{target}}
next prev parent reply other threads:[~2008-09-16 16:49 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-09-15 9:19 [PATCH] Documentation: Quote ~(s) causing subscript Thomas Rast
2008-09-15 9:19 ` [PATCH] Documenation: git-bundle: quote tildes that cause subscript Thomas Rast
2008-09-15 9:19 ` [PATCH] Documentation: replace [^~] with escapes everywhere Thomas Rast
2008-09-15 23:56 ` Avery Pennarun
2008-09-16 0:05 ` Thomas Rast
2008-09-16 0:10 ` Avery Pennarun
2008-09-16 8:24 ` Junio C Hamano
2008-09-16 12:47 ` [PATCH] Documentation: disable sub/superscript characters ^/~ Thomas Rast
2008-09-16 15:58 ` [PATCH] Documentation: replace [^~] with escapes everywhere Avery Pennarun
2008-09-16 16:34 ` Junio C Hamano
2008-09-16 16:48 ` Junio C Hamano [this message]
2008-09-16 19:12 ` Jeff King
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7vhc8g6nqt.fsf@gitster.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=apenwarr@gmail.com \
--cc=git@vger.kernel.org \
--cc=trast@student.ethz.ch \
/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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.