From: Junio C Hamano <gitster@pobox.com>
To: "Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
Cc: git@vger.kernel.org, "Jean-Noël Avila" <jn.avila@free.fr>,
"Johannes Schindelin" <johannes.schindelin@gmx.de>
Subject: Re: [PATCH] asciidoctor: fix `synopsis` rendering
Date: Sat, 20 Jul 2024 16:01:12 -0700 [thread overview]
Message-ID: <xmqqsew3hdmv.fsf@gitster.g> (raw)
In-Reply-To: <pull.1749.git.git.1721507416683.gitgitgadget@gmail.com> (Johannes Schindelin via GitGitGadget's message of "Sat, 20 Jul 2024 20:30:16 +0000")
"Johannes Schindelin via GitGitGadget" <gitgitgadget@gmail.com>
writes:
> From: Johannes Schindelin <johannes.schindelin@gmx.de>
>
> Since 76880f0510c (doc: git-clone: apply new documentation formatting
> guidelines, 2024-03-29), the synopsis of `git clone`'s manual page is
> rendered differently than before; Its parent commit did the same for
> `git init`.
>
> The result looks quite nice. When rendered with AsciiDoc, that is. When
> rendered using AsciiDoctor, the result is quite unpleasant to my eye,
> reading something like this:
>
> SYNOPSIS
>
> git clone
> [
> --template=
> <template-directory>]
> [
> -l
> ] [
> -s
> ] [
> --no-hardlinks
> ] [
> -q
> ] [
> [... continuing like this ...]
Hmph, this may probably depend on the version of asciidoctor, but I
am getting quite different output. It looks very similar to what is
shown at https://git-scm.com/docs/git-clone/2.45.0.
Even more puzzling, with or without this patch applied, I do not see
any difference in the rendered output of samples I used, which were
"clone", which has the changes from 76880f0510c and "add", which
hasn't been broken by the series.
$ make -C Documentation USE_ASCIIDOCTOR=YesPlease git-{clone,add}.{html,1}
$ man -l Documentation/git-clone.1
$ lynx Documentation/git-clone.html
$ man -l Documentation/git-add.1
$ lynx Documentation/git-add.html
The rendered result is bad in the same way with or without this
patch applied, and "git clone" manual page is simply incorrect by
mangling a handful of command line options. A recent bug report in
the thread that contains
https://lore.kernel.org/git/xmqqle1xjm1s.fsf@gitster.g/
gives us more details.
> diff --git a/Documentation/Makefile b/Documentation/Makefile
> index 3f2383a12c7..78e407e4bd1 100644
> --- a/Documentation/Makefile
> +++ b/Documentation/Makefile
> @@ -202,6 +202,7 @@ ASCIIDOC_DOCBOOK = docbook5
> ASCIIDOC_EXTRA += -acompat-mode -atabsize=8
> ASCIIDOC_EXTRA += -I. -rasciidoctor-extensions
> ASCIIDOC_EXTRA += -alitdd='&\#x2d;&\#x2d;'
> +ASCIIDOC_EXTRA += -adocinfo=shared
> ASCIIDOC_DEPS = asciidoctor-extensions.rb GIT-ASCIIDOCFLAGS
> DBLATEX_COMMON =
> XMLTO_EXTRA += --skip-validation
> diff --git a/Documentation/docinfo.html b/Documentation/docinfo.html
> new file mode 100644
> index 00000000000..fb3560eb92b
> --- /dev/null
> +++ b/Documentation/docinfo.html
> @@ -0,0 +1,5 @@
> +<style>
> +pre>code {
> + display: inline;
> +}
> +</style>
>
> base-commit: 76880f0510c6be9f6385f2d43dcfcba4eca9ccbc
next prev parent reply other threads:[~2024-07-20 23:01 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-20 20:30 [PATCH] asciidoctor: fix `synopsis` rendering Johannes Schindelin via GitGitGadget
2024-07-20 23:01 ` Junio C Hamano [this message]
2024-07-21 0:01 ` Junio C Hamano
2024-07-22 16:27 ` Junio C Hamano
2024-07-22 20:25 ` [PATCH v2] " Johannes Schindelin via GitGitGadget
2024-07-22 20:45 ` Junio C Hamano
2024-07-23 3:13 ` Junio C Hamano
2024-07-23 14:19 ` Johannes Schindelin
2024-07-23 16:43 ` Junio C Hamano
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=xmqqsew3hdmv.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=gitgitgadget@gmail.com \
--cc=jn.avila@free.fr \
--cc=johannes.schindelin@gmx.de \
/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 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 NNTP newsgroup(s).