git@vger.kernel.org list mirror (unofficial, one of many)
 help / color / mirror / Atom feed
* [PATCH] gitsubmodules: align html and nroff lists
@ 2019-05-01 20:32 Emily Shaffer
  2019-05-01 21:03 ` Jeff King
  0 siblings, 1 reply; 4+ messages in thread
From: Emily Shaffer @ 2019-05-01 20:32 UTC (permalink / raw)
  To: git; +Cc: Emily Shaffer

There appears to be a bug in the toolchain generating manpages from
lettered lists. When a list is enumerated with letters, the resulting
nroff shows numbers instead. Mostly this is harmless, but in the case of
gitsubmodules, the paragraph following the list refers back to each
bullet by letter. As a result, reading this documentation via `man
gitsubmodules` is hard to parse - readers must infer that a bug exists
and a refers to 1, b refers to 2, and c refers to 3 in the list above.

The problem specifically was introduced in ad47194; previously rather
than generating numerated lists the bulleted area was entirely
monospaced in HTML and shown in plaintext in nroff.

The bug seems to exist in docbook-xml - I've reported it on May 1 via
the docbook-apps mail list - but for now it may make more sense to just
work around the issue.

Signed-off-by: Emily Shaffer <emilyshaffer@google.com>
---
 Documentation/gitsubmodules.txt | 14 +++++++-------
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/Documentation/gitsubmodules.txt b/Documentation/gitsubmodules.txt
index 57999e9f36..0a890205b8 100644
--- a/Documentation/gitsubmodules.txt
+++ b/Documentation/gitsubmodules.txt
@@ -169,15 +169,15 @@ ACTIVE SUBMODULES
 
 A submodule is considered active,
 
-  a. if `submodule.<name>.active` is set to `true`
+  1. if `submodule.<name>.active` is set to `true`
 +
 or
 
-  b. if the submodule's path matches the pathspec in `submodule.active`
+  2. if the submodule's path matches the pathspec in `submodule.active`
 +
 or
 
-  c. if `submodule.<name>.url` is set.
+  3. if `submodule.<name>.url` is set.
 
 and these are evaluated in this order.
 
@@ -193,11 +193,11 @@ For example:
     url = https://example.org/baz
 
 In the above config only the submodule 'bar' and 'baz' are active,
-'bar' due to (a) and 'baz' due to (c). 'foo' is inactive because
-(a) takes precedence over (c)
+'bar' due to (1) and 'baz' due to (3). 'foo' is inactive because
+(1) takes precedence over (3)
 
-Note that (c) is a historical artefact and will be ignored if the
-(a) and (b) specify that the submodule is not active. In other words,
+Note that (3) is a historical artefact and will be ignored if the
+(1) and (2) specify that the submodule is not active. In other words,
 if we have a `submodule.<name>.active` set to `false` or if the
 submodule's path is excluded in the pathspec in `submodule.active`, the
 url doesn't matter whether it is present or not. This is illustrated in
-- 
2.21.0.1020.gf2820cf01a-goog


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] gitsubmodules: align html and nroff lists
  2019-05-01 20:32 [PATCH] gitsubmodules: align html and nroff lists Emily Shaffer
@ 2019-05-01 21:03 ` Jeff King
  2019-05-20 20:54   ` Jonathan Nieder
  0 siblings, 1 reply; 4+ messages in thread
From: Jeff King @ 2019-05-01 21:03 UTC (permalink / raw)
  To: Emily Shaffer; +Cc: git

On Wed, May 01, 2019 at 01:32:17PM -0700, Emily Shaffer wrote:

> There appears to be a bug in the toolchain generating manpages from
> lettered lists. When a list is enumerated with letters, the resulting
> nroff shows numbers instead. Mostly this is harmless, but in the case of
> gitsubmodules, the paragraph following the list refers back to each
> bullet by letter. As a result, reading this documentation via `man
> gitsubmodules` is hard to parse - readers must infer that a bug exists
> and a refers to 1, b refers to 2, and c refers to 3 in the list above.

Yikes, I see this, too.

> The problem specifically was introduced in ad47194; previously rather
> than generating numerated lists the bulleted area was entirely
> monospaced in HTML and shown in plaintext in nroff.

I wondered briefly if ad47194 was doing the wrong thing to convert this
section, but I think its _intent_ was right. Its author just didn't
anticipate this bug. :)

> The bug seems to exist in docbook-xml - I've reported it on May 1 via
> the docbook-apps mail list - but for now it may make more sense to just
> work around the issue.

Yeah. Specifically, the HTML generated directly from asciidoc doesn't
have this bug. Likewise, using asciidoctor has no impact (though in
theory if we eventually move to generating roff directly from
asciidoctor, the problem might go away).

I agree with you that it's worth working around in the meantime.

The patch itself looks good to me. A few observations:

>  A submodule is considered active,
>  
> -  a. if `submodule.<name>.active` is set to `true`
> +  1. if `submodule.<name>.active` is set to `true`

I'd sometimes use letters when there is already a nearby list using
numbers (and I need to be able to refer to either list distinctly). But
I checked the surrounding context and don't think that's the case here.

> -Note that (c) is a historical artefact and will be ignored if the

Not introduced by your patch, but it may be worth swapping this out for
"artifact". The spelling with the "e" is apparently a British-ism (today
I learned!), but I think we usually favor (favour!?) American spellings
in our documentation.

Obviously not super important, and definitely should be addressed in a
separate patch (if at all).

-Peff

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] gitsubmodules: align html and nroff lists
  2019-05-01 21:03 ` Jeff King
@ 2019-05-20 20:54   ` Jonathan Nieder
  2019-05-28 16:42     ` Junio C Hamano
  0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Nieder @ 2019-05-20 20:54 UTC (permalink / raw)
  To: Jeff King; +Cc: Emily Shaffer, git, Junio C Hamano

Jeff King wrote:

> The patch itself looks good to me.

For what it's worth,

Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>

as well.  It's a straightforward patch and solves the reader-facing
problem.  Thanks.

For the curious, the upstream discussion in docbook-xsl is
https://lists.oasis-open.org/archives/docbook-apps/201905/msg00001.html.
I'm not sure where their bug tracker lives and what bug number this has
there.

Thanks,
Jonathan

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] gitsubmodules: align html and nroff lists
  2019-05-20 20:54   ` Jonathan Nieder
@ 2019-05-28 16:42     ` Junio C Hamano
  0 siblings, 0 replies; 4+ messages in thread
From: Junio C Hamano @ 2019-05-28 16:42 UTC (permalink / raw)
  To: Jonathan Nieder; +Cc: Jeff King, Emily Shaffer, git

Jonathan Nieder <jrnieder@gmail.com> writes:

> Jeff King wrote:
>
>> The patch itself looks good to me.
>
> For what it's worth,
>
> Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
>
> as well.  It's a straightforward patch and solves the reader-facing
> problem.  Thanks.

Thanks, all.

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-05-28 16:42 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-01 20:32 [PATCH] gitsubmodules: align html and nroff lists Emily Shaffer
2019-05-01 21:03 ` Jeff King
2019-05-20 20:54   ` Jonathan Nieder
2019-05-28 16:42     ` Junio C Hamano

git@vger.kernel.org list mirror (unofficial, one of many)

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V1 git git/ https://public-inbox.org/git \
		git@vger.kernel.org
	public-inbox-index git

Example config snippet for mirrors.
Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.io/gmane.comp.version-control.git
 note: .onion URLs require Tor: https://www.torproject.org/

code repositories for the project(s) associated with this inbox:

	https://80x24.org/mirrors/git.git

AGPL code for this site: git clone https://public-inbox.org/public-inbox.git