All of lore.kernel.org
 help / color / mirror / Atom feed
From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: "Martin Ågren" <martin.agren@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH 3/3] asciidoctor-extensions: fix spurious space after linkgit
Date: Tue, 26 Feb 2019 03:20:00 +0000	[thread overview]
Message-ID: <20190226032000.GC601925@genre.crustytoothpaste.net> (raw)
In-Reply-To: <41d9ea21c37a634b2310b5b2f68935bcd612665c.1551123979.git.martin.agren@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1787 bytes --]

On Mon, Feb 25, 2019 at 09:02:40PM +0100, Martin Ågren wrote:
> When we render, e.g., "linkgit:gitglossary[7]." with Asciidoctor, we get
> "gitglossary(7) ." with a space between the linkgit macro expansion and
> the punctuation. We can fix this by dropping the trailing newline after
> we've turned `linkgit:foo[bar]` into `<citerefentry>..</citerefentry>`.
> 
> The diff produced by `USE_ASCIIDOCTOR=Yes ./doc-diff HEAD^ HEAD` is
> almost 6000 lines large and shows how this fixes "git-foo(x) ,", "(see
> git-bar(y) )" and so on. One might wonder whether this also turns, e.g.,
> "see linkgit:foo[1] for more" into "see foo(1)for more", but no. We get
> "...</citerefentry> for more" in the XML, see, e.g., git-am.xml, so the
> space ends up in git-am.1 just fine.
> 
> Signed-off-by: Martin Ågren <martin.agren@gmail.com>
> ---
>  Documentation/asciidoctor-extensions.rb | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/Documentation/asciidoctor-extensions.rb b/Documentation/asciidoctor-extensions.rb
> index ec83b4959e..f7a5982f8b 100644
> --- a/Documentation/asciidoctor-extensions.rb
> +++ b/Documentation/asciidoctor-extensions.rb
> @@ -16,7 +16,7 @@ module Git
>            "<citerefentry>\n" \
>              "<refentrytitle>#{target}</refentrytitle>" \
>              "<manvolnum>#{attrs[1]}</manvolnum>\n" \
> -          "</citerefentry>\n"
> +          "</citerefentry>"
>          end
>        end
>      end

Yeah, I think this is clearly correct. I also like that you mentioned
the concern about potentially not including the space, which might not
be obvious to someone not intimately familiar with DocBook and the
stylesheets.
-- 
brian m. carlson: Houston, Texas, US
OpenPGP: https://keybase.io/bk2204

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 868 bytes --]

  reply	other threads:[~2019-02-26  3:20 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-25 20:02 [PATCH 0/3] asciidoctor-extensions: fix spurious space after linkgit Martin Ågren
2019-02-25 20:02 ` [PATCH 1/3] Documentation/Makefile: add missing xsl dependencies for manpages Martin Ågren
2019-02-25 20:08   ` Eric Sunshine
2019-02-25 20:28     ` Martin Ågren
2019-02-25 21:00       ` Eric Sunshine
2019-02-26  5:59         ` Martin Ågren
2019-02-26 12:47           ` Eric Sunshine
2019-02-27 18:19             ` Martin Ågren
2019-02-25 20:02 ` [PATCH 2/3] Documentation/Makefile: add missing dependency on asciidoctor-extensions Martin Ågren
2019-02-25 20:02 ` [PATCH 3/3] asciidoctor-extensions: fix spurious space after linkgit Martin Ågren
2019-02-26  3:20   ` brian m. carlson [this message]
2019-02-26  3:22 ` [PATCH 0/3] " brian m. carlson
2019-02-26  6:03   ` Martin Ågren
2019-02-27 18:17     ` [PATCH v2 " Martin Ågren
2019-02-27 18:17       ` [PATCH v2 1/3] Documentation/Makefile: add missing xsl dependencies for manpages Martin Ågren
2019-02-27 18:17       ` [PATCH v2 2/3] Documentation/Makefile: add missing dependency on asciidoctor-extensions Martin Ågren
2019-02-27 18:17       ` [PATCH v2 3/3] asciidoctor-extensions: fix spurious space after linkgit Martin Ågren
2019-02-28 23:50       ` [PATCH v2 0/3] " brian m. carlson
2019-03-03  1:25         ` Junio C Hamano
2019-03-10 15:14           ` [PATCH 0/2] fix spurious space after linkgit, now in *.html Martin Ågren
2019-03-10 15:14             ` [PATCH 1/2] Documentation/Makefile: add missing dependencies on asciidoctor-extensions Martin Ågren
2019-03-10 15:14             ` [PATCH 2/2] asciidoctor-extensions: fix spurious space after linkgit in *.html Martin Ågren
2019-03-11  2:59             ` [PATCH 0/2] fix spurious space after linkgit, now " Jeff King
2019-03-11  5:47               ` Martin Ågren
2019-03-11  3:02             ` Junio C Hamano
2019-03-11  5:40               ` Martin Ågren
2019-03-11  9:24                 ` Junio C Hamano
2019-03-11  9:26                   ` [PATCH v3 1/3] Documentation/Makefile: add missing xsl dependencies for manpages Junio C Hamano
2019-03-11  9:26                     ` [PATCH v3 2/3] Documentation/Makefile: add missing dependency on asciidoctor-extensions Junio C Hamano
2019-03-11  9:26                     ` [PATCH v3 3/3] asciidoctor-extensions: fix spurious space after linkgit Junio C Hamano
2019-03-11 11:02                   ` [PATCH 0/2] fix spurious space after linkgit, now in *.html Martin Ågren

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=20190226032000.GC601925@genre.crustytoothpaste.net \
    --to=sandals@crustytoothpaste.net \
    --cc=git@vger.kernel.org \
    --cc=martin.agren@gmail.com \
    /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.