lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ff9ee361-cb1e-26c3-c14d-f4bc1c1a9059@gmail.com>
Date:   Tue, 9 May 2023 00:09:57 +0900
From:   Akira Yokosawa <akiyks@...il.com>
To:     bagasdotme@...il.com, rdunlap@...radead.org
Cc:     devicetree@...r.kernel.org, grant.likely@...aro.org,
        krzysztof.kozlowski+dt@...aro.org, linus.walleij@...aro.org,
        linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
        robh+dt@...nel.org, Akira Yokosawa <akiyks@...il.com>
Subject: Re: [PATCH v2] docs: dt: Make references and mention kernel
 abstractions

Hi,

On Date: Mon, 8 May 2023 21:13:05 +0700, Bagas Sanjaya wrote:
> On Sat, May 06, 2023 at 03:09:11PM -0700, Randy Dunlap wrote:
>> For @linux-doc: Is there something in ReST that does auto section numbering
>> so that this renumbering does not have to be repeated in the future?
>> 
> 
> There is sectnum:: directive which does the job. In the kernel docs,

Just for you info:

In Sphinx documentation at:
    https://www.sphinx-doc.org/en/master/usage/restructuredtext/basics.html#directives

has a warning which reads:

    Warning
    Do not use the directives sectnum, header and footer. 

Sphinx prefers the the :numbered: option of the toctree:: directive.
See https://www.sphinx-doc.org/en/master/usage/restructuredtext/directives.html#directive-toctree

This directive applies to the documentation as a whole, not to each .rst
file.

An example is at:
    https://www.kernel.org/doc/html/latest/process/development-process.html

Just my two cents.

        Thanks, Akira

> however, it is customarily used together with contents:: directive to
> generate toctree for current doc. In order for this to work as expected,
> you need also to rearrange section heading levels, like:
> 
> ---- >8 ----
> diff --git a/Documentation/devicetree/usage-model.rst b/Documentation/devicetree/usage-model.rst
> index 87f522d5feba81..890dde293540f9 100644
> --- a/Documentation/devicetree/usage-model.rst
> +++ b/Documentation/devicetree/usage-model.rst
> @@ -1,5 +1,8 @@
>  .. SPDX-License-Identifier: GPL-2.0
>  
> +.. contents::
> +.. sectnum::
> +
>  ========================
>  Linux and the Devicetree
>  ========================

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ