Re: doc: add missing "id" attributes to extension packaging page

From: "Karl O(dot) Pinc" <kop(at)karlpinc(dot)com>
To: Brar Piening <brar(at)gmx(dot)de>
Cc: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Ian Lawrence Barwick <barwick(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: doc: add missing "id" attributes to extension packaging page
Date: 2023-01-02 20:53:54
Message-ID: 20230102145354.6857a730@slate.karlpinc.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hello,

Attached is a new patch (add_html_ids_v2.patch), almost identical to
the old but modified so that it applies. There were 2 changes (made
to sgml/plpgsql.stml and sgml/ddl.sgml) that prevented the patch from
applying. (In ddl.sgml the VACUUM and ANALYZE privileges were
combined into MAINTAIN. In plpgsql.sgml an id attribute was added.)

If the author will look over my version of the patch I believe it can
be approved and sent on to the committers.

What follows is my notes for the committers:

The ids look reasonably consistent, with "nesting" so that ids of
sub-sections mostly have (at least some of) the id of the parent
section as a prefix. There are a few inconsistencies. A sect3 has
id="collation-managing-standard" and sect4 has
id="collation-managing-predefined". There is a slight possibility of
conflict, as in this case sect4 ids omit the last word of the section
3 ids it is possible to have conflicts with the ids of the sect4s in
other sect3s of the same file. I don't have a problem with this.

(I see establishing strict standards for id values as excessive.)

The above was the only case I noticed. I also tried counting words,
"-" delimited, in ids and found no cases with fewer words than the
number of section levels. Here's the hack:

egrep '^\+ *<sect' /tmp/add_html_ids.patch \
| gawk '{if (int(substr($2, length($2), 1)) < split($2, dummy, "-"))
print $0;}'

As far as I know the ids are consistent with the rest of the
documentation. They are not entirely consistent in construction.
Mostly they copy the section title, but sometimes words are omitted.
E.g in sgml/charset.sgml where sect2 is "Managing Collations" with
id="collation-managing" and sect3 is "Standard Collations" with
id="collation-managing-standard". Also there is at least one
abbreviation in the id of a word in the title.
(id="installation-notes-aix-mem-management" v.s a title of "Memory
Management") All this seems fine to me.

The ids are sometimes very long. This also seems ok.

I did not do a particularly close look at the id values for
varlistentrys. Scanning the patch they seem fine.

I can confirm that all the patch does is add ids.

Regards,

Karl <kop(at)karlpinc(dot)com>
Free Software: "You don't pay back, you pay forward."
-- Robert A. Heinlein

Attachment Content-Type Size
add_html_ids_v2.patch text/x-patch 371.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dag Lem 2023-01-02 21:00:34 Re: daitch_mokotoff module
Previous Message Maciek Sakrejda 2023-01-02 20:44:42 Re: Reduce timing overhead of EXPLAIN ANALYZE using rdtsc?