linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jonathan Neuschäfer" <j.neuschaefer@gmx.net>
To: Jonathan Corbet <corbet@lwn.net>
Cc: "Jonathan Neuschäfer" <j.neuschaefer@gmx.net>,
	linux-doc@vger.kernel.org, "Andi Kleen" <ak@linux.intel.com>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	"Randy Dunlap" <rdunlap@infradead.org>,
	"Darrick J. Wong" <darrick.wong@oracle.com>,
	"Arnd Bergmann" <arnd@arndb.de>,
	"Chang S. Bae" <chang.seok.bae@intel.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] docs: process: changes.rst: Escape --version to fix Sphinx output
Date: Mon, 24 Feb 2020 19:47:19 +0100	[thread overview]
Message-ID: <20200224184719.GA2363@latitude> (raw)
In-Reply-To: <20200224110815.6f7561d1@lwn.net>

[-- Attachment #1: Type: text/plain, Size: 1438 bytes --]

On Mon, Feb 24, 2020 at 11:08:15AM -0700, Jonathan Corbet wrote:
> On Sun, 23 Feb 2020 23:22:27 +0100
> Jonathan Neuschäfer <j.neuschaefer@gmx.net> wrote:
> 
> > Without double-backticks, Sphinx wrongly turns "--version" into
> > "–version" with a Unicode EN DASH (U+2013), that is visually easy to
> > confuse with a single ASCII dash.
> > 
> > Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@gmx.net>
> 
> This certainly seems worth addressing.  But I would *really* rather find
> a way to tell Sphinx not to do that rather than making all of these
> tweaks - which we will certainly find ourselves having to do over and
> over again.  I can try to look into that in a bit, but if somebody were
> to beat me to it ... :)

This seems to do the trick:


diff --git a/Documentation/conf.py b/Documentation/conf.py
index 3c7bdf4cd31f..8f2a7ae95184 100644
--- a/Documentation/conf.py
+++ b/Documentation/conf.py
@@ -587,6 +587,9 @@ pdf_documents = [
 kerneldoc_bin = '../scripts/kernel-doc'
 kerneldoc_srctree = '..'

+# Render -- as two dashes
+smartquotes = False
+
 # ------------------------------------------------------------------------------
 # Since loadConfig overwrites settings from the global namespace, it has to be
 # the last statement in the conf.py file

(Documentation at https://www.sphinx-doc.org/en/master/usage/configuration.html#confval-smartquotes)


Jonathan Neuschäfer

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2020-02-24 18:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-23 22:22 [PATCH] docs: process: changes.rst: Escape --version to fix Sphinx output Jonathan Neuschäfer
2020-02-24 18:08 ` Jonathan Corbet
2020-02-24 18:47   ` Jonathan Neuschäfer [this message]
2020-02-24 18:52     ` Matthew Wilcox
2020-02-24 18:58       ` Jonathan Corbet
2020-02-24 19:12         ` Matthew Wilcox
2020-02-24 21:08           ` Randy Dunlap
2020-02-24 21:10             ` Matthew Wilcox
2020-02-25  9:15               ` Jani Nikula

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=20200224184719.GA2363@latitude \
    --to=j.neuschaefer@gmx.net \
    --cc=ak@linux.intel.com \
    --cc=arnd@arndb.de \
    --cc=chang.seok.bae@intel.com \
    --cc=corbet@lwn.net \
    --cc=darrick.wong@oracle.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rdunlap@infradead.org \
    --cc=tglx@linutronix.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).