File: docs-Don-t-try-to-detect-the-version-don-t-use-Pylons-the.patch

package info (click to toggle)
waitress 2.1.2-2%2Bdeb12u1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,256 kB
  • sloc: python: 10,904; makefile: 81; sh: 25
file content (73 lines) | stat: -rw-r--r-- 2,225 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
From: Andrew Shadura <andrewsh@debian.org>
Date: Mon, 9 May 2022 17:41:08 -0400
Subject: docs: Don't try to detect the version, don't use Pylons theme

Forwarded: not-needed
---
 docs/conf.py | 32 +++++++++++++++++---------------
 1 file changed, 17 insertions(+), 15 deletions(-)

diff --git a/docs/conf.py b/docs/conf.py
index cf0ff9b..6929b78 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -18,8 +18,8 @@
 # sys.path.append(os.path.abspath('some/directory'))
 
 import datetime
-import pkg_resources
-import pylons_sphinx_themes
+from subprocess import check_output
+# import pylons_sphinx_themes
 
 # General configuration
 # ---------------------
@@ -53,7 +53,9 @@ copyright = "2012-%s, Agendaless Consulting <chrism@plope.com>" % thisyear
 # other places throughout the built documents.
 #
 # The short X.Y version.
-version = pkg_resources.get_distribution("waitress").version
+version = check_output(
+    ('dpkg-parsechangelog', '-S', 'Version', '-l', '../debian/changelog'),
+    encoding='UTF-8').strip()
 # The full version, including alpha/beta/rc tags.
 release = version
 
@@ -100,9 +102,9 @@ smartquotes = False
 # -----------------------
 
 # Add and use Pylons theme
-html_theme = "pylons"
-html_theme_path = pylons_sphinx_themes.get_html_themes_path()
-html_theme_options = dict(github_url="https://github.com/Pylons/waitress")
+# html_theme = "pylons"
+# html_theme_path = pylons_sphinx_themes.get_html_themes_path()
+# html_theme_options = dict(github_url="https://github.com/Pylons/waitress")
 
 # The style sheet to use for HTML and HTML Help pages. A file of that name
 # must exist either in Sphinx' static/ path, or in one of the custom paths
@@ -172,15 +174,15 @@ html_last_updated_fmt = "%b %d, %Y"
 htmlhelp_basename = "waitress"
 
 # Control display of sidebars
-html_sidebars = {
-    "**": [
-        "localtoc.html",
-        "ethicalads.html",
-        "relations.html",
-        "sourcelink.html",
-        "searchbox.html",
-    ]
-}
+# html_sidebars = {
+#     "**": [
+#         "localtoc.html",
+#         "ethicalads.html",
+#         "relations.html",
+#         "sourcelink.html",
+#         "searchbox.html",
+#     ]
+# }
 
 # Options for LaTeX output
 # ------------------------