linux-doc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] docs: sphinx-pre-install: don't barf on beta Sphinx releases
@ 2021-04-15 22:06 Jonathan Corbet
  0 siblings, 0 replies; only message in thread
From: Jonathan Corbet @ 2021-04-15 22:06 UTC (permalink / raw)
  To: linux-doc; +Cc: Mauro Carvalho Chehab

sphinx-pre-install is picky when it comes to parsing sphinx versions; it
fails, killing the docs build, when run with sphinx 4.0.0b1.  Tweak the
regex to tolerate a trailing "bN" on the version number.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>
---
The good news is that this appears to be the only thing that explodes
with Sphinx 4.0...

 scripts/sphinx-pre-install | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/sphinx-pre-install b/scripts/sphinx-pre-install
index b5f9fd5b2880..fe92020d67e3 100755
--- a/scripts/sphinx-pre-install
+++ b/scripts/sphinx-pre-install
@@ -259,7 +259,7 @@ sub get_sphinx_version($)
 
 	open IN, "$cmd --version 2>&1 |";
 	while (<IN>) {
-		if (m/^\s*sphinx-build\s+([\d\.]+)(\+\/[\da-f]+)?$/) {
+		if (m/^\s*sphinx-build\s+([\d\.]+)((\+\/[\da-f]+)|(b\d+))?$/) {
 			$ver=$1;
 			last;
 		}
-- 
2.30.2


^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2021-04-15 22:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-15 22:06 [PATCH] docs: sphinx-pre-install: don't barf on beta Sphinx releases Jonathan Corbet

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).