public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Akira Yokosawa <akiyks@gmail.com>
To: rdunlap@infradead.org
Cc: bagasdotme@gmail.com, ivan.orlov0322@gmail.com, lenb@kernel.org,
	linux-acpi@vger.kernel.org, linux-doc@vger.kernel.org,
	linux-kernel@vger.kernel.org, madhumithabiw@gmail.com,
	rafael@kernel.org, skhan@linuxfoundation.org,
	Akira Yokosawa <akiyks@gmail.com>
Subject: Re: [PATCH] docs: Fix warning:Error in "code-block" directive
Date: Sat, 3 Jun 2023 13:04:04 +0900	[thread overview]
Message-ID: <bf0dee59-20ce-27d6-5b6a-683525fc012e@gmail.com> (raw)
In-Reply-To: <e69410c1-8632-354e-e6e0-ac16631f0566@infradead.org>

On Fri, 2 Jun 2023 18:41:46 -0700, Randy Dunlap wrote:
> On 6/2/23 18:20, Bagas Sanjaya wrote:
>> On Fri, Jun 02, 2023 at 04:51:02PM -0500, Madhumitha Prabakaran wrote:
>>> Fix the error in "code-block" directive by providing the
>>> argument as "text".
>>>
>>> <snipped> ...
>>>  Result code:
>>>  ------------
>>>  
>>> -.. code-block::
>>> +.. code-block:: text
>> 
>> Nope.
>> 
>> I don't see error you mention in this patch when making htmldocs on my
>> computer (my setup is pretty standard: see
>> Documentation/doc-guide/sphinx.rst). This patch is unneccessary, though,
>> unless you have code snippets in some language (e.g. C, where passing
>> language name to code-block:: syntax-highlight it). Result code outputs,
>> on the other hand, are generic text with no definitive syntax, hence
>> you can omit language name.
>> 
>> Thanks.
> 
> 
> I also don't see any such warnings so I don't see a need for this patch.
> My wild guess is that some older version of Sphinx was being used.

Right.

In Sphinx changelog, "Features added" for 2.0.0b1 [1] lists this:

    #1851: Allow to omit an argument for code-block directive. If omitted,
    it follows highlight or highlight_language

[1]: https://www.sphinx-doc.org/en/master/changes.html#id1306

Pre-2.0 Sphinx is now deprecated.
See commit 31abfdda6527 ("docs: Deprecate use of Sphinx < 2.4.x").

        Thanks, Akira    

> 
> -- 
> ~Randy


  reply	other threads:[~2023-06-03  4:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-02 21:51 [PATCH] docs: Fix warning:Error in "code-block" directive Madhumitha Prabakaran
2023-06-03  1:20 ` Bagas Sanjaya
2023-06-03  1:41   ` Randy Dunlap
2023-06-03  4:04     ` Akira Yokosawa [this message]
     [not found]       ` <CAPNSgDiZiv6VJcX66DaQjHkLjd3ZxhkBcXzo7UU5LUD2hCx9Sw@mail.gmail.com>
2023-06-03 22:55         ` Fwd: " Madhumitha Prabakaran

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=bf0dee59-20ce-27d6-5b6a-683525fc012e@gmail.com \
    --to=akiyks@gmail.com \
    --cc=bagasdotme@gmail.com \
    --cc=ivan.orlov0322@gmail.com \
    --cc=lenb@kernel.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=madhumithabiw@gmail.com \
    --cc=rafael@kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=skhan@linuxfoundation.org \
    /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