gnu: Add python-pytest-regressions.
[jackhill/guix/guix.git] / gnu / packages / sphinx.scm
CommitLineData
9d0c291e
MB
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2014 David Thompson <davet@gnu.org>
a818a34f 3;;; Copyright © 2015, 2017, 2019, 2020, 2021 Ricardo Wurmus <rekado@elephly.net>
9d0c291e
MB
4;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name>
5;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com>
6;;; Copyright © 2016, 2017, 2018, 2019 Marius Bakke <mbakke@fastmail.com>
7;;; Copyright © 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
f49b8c14 8;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
9d0c291e
MB
9;;; Copyright © 2017 Frederick M. Muriithi <fredmanglis@gmail.com>
10;;; Copyright © 2017 Christopher Allan Webber <cwebber@dustycloud.org>
11;;; Copyright © 2017 Julien Lepiller <julien@lepiller.eu>
12;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
e5c1348a 13;;; Copyright © 2019, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr>
90ee17cd 14;;; Copyright © 2019 Alexandros Theodotou <alex@zrythm.org>
0066f6be 15;;; Copyright © 2019 Brett Gilio <brettg@gnu.org>
83ade5bf 16;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
b1572018 17;;; Copyright © 2021 Eric Bavier <bavier@posteo.net>
51e85395 18;;; Copyright © 2021 Vinicius Monego <monego@posteo.net>
9d0c291e
MB
19;;;
20;;; This file is part of GNU Guix.
21;;;
22;;; GNU Guix is free software; you can redistribute it and/or modify it
23;;; under the terms of the GNU General Public License as published by
24;;; the Free Software Foundation; either version 3 of the License, or (at
25;;; your option) any later version.
26;;;
27;;; GNU Guix is distributed in the hope that it will be useful, but
28;;; WITHOUT ANY WARRANTY; without even the implied warranty of
29;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
30;;; GNU General Public License for more details.
31;;;
32;;; You should have received a copy of the GNU General Public License
33;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
34
35(define-module (gnu packages sphinx)
36 #:use-module (guix packages)
37 #:use-module (guix download)
d090a1c1 38 #:use-module (guix git-download)
d309b36d 39 #:use-module (guix utils)
9d0c291e
MB
40 #:use-module (guix build-system python)
41 #:use-module ((guix licenses) #:prefix license:)
42 #:use-module (gnu packages)
43 #:use-module (gnu packages check)
44 #:use-module (gnu packages graphviz)
45 #:use-module (gnu packages image)
46 #:use-module (gnu packages imagemagick)
dbcd2050 47 #:use-module (gnu packages python-build)
1ed435bf 48 #:use-module (gnu packages python-crypto)
9d0c291e
MB
49 #:use-module (gnu packages python-web)
50 #:use-module (gnu packages python-xyz)
51 #:use-module (gnu packages time))
52
53(define-public python-sphinx
54 (package
55 (name "python-sphinx")
9fe0ca40 56 (version "3.3.1")
9d0c291e
MB
57 (source
58 (origin
59 (method url-fetch)
60 (uri (pypi-uri "Sphinx" version))
61 (sha256
62 (base32
9fe0ca40 63 "0023vc2i29pjxmvdqbz1wdbi7gbj56y1br1b2z8h8wa44li5k38y"))))
9d0c291e
MB
64 (build-system python-build-system)
65 (arguments
66 `(#:phases
67 (modify-phases %standard-phases
68 (replace 'check
69 (lambda _
70 ;; Requires Internet access.
71 (delete-file "tests/test_build_linkcheck.py")
72 (substitute* "tests/test_build_latex.py"
73 (("@pytest.mark.sphinx\\('latex', testroot='images'\\)")
74 "@pytest.mark.skip()"))
9d0c291e
MB
75 (invoke "make" "test"))))))
76 (propagated-inputs
4b8c8f76 77 `(("python-babel" ,python-babel)
9d0c291e
MB
78 ("python-docutils" ,python-docutils)
79 ("python-jinja2" ,python-jinja2)
4b8c8f76 80 ("python-imagesize" ,python-imagesize)
9d0c291e
MB
81 ("python-packaging" ,python-packaging)
82 ("python-pygments" ,python-pygments)
83 ("python-requests" ,python-requests)
4b8c8f76
BG
84 ("python-snowballstemmer" ,python-snowballstemmer)
85 ("python-sphinx-alabaster-theme"
86 ,python-sphinx-alabaster-theme)
d309b36d
MB
87 ("python-sphinxcontrib-applehelp" ,python-sphinxcontrib-applehelp)
88 ("python-sphinxcontrib-devhelp" ,python-sphinxcontrib-devhelp)
89 ("python-sphinxcontrib-htmlhelp" ,python-sphinxcontrib-htmlhelp)
90 ("python-sphinxcontrib-jsmath" ,python-sphinxcontrib-jsmath)
91 ("python-sphinxcontrib-qthelp" ,python-sphinxcontrib-qthelp)
92 ("python-sphinxcontrib-serializinghtml"
93 ,python-sphinxcontrib-serializinghtml)))
9d0c291e
MB
94 (native-inputs
95 `(("graphviz" ,graphviz)
96 ("imagemagick" ,imagemagick) ;for "convert"
97 ("python-html5lib" ,python-html5lib)
98 ("python-mock" ,python-mock)
99 ("python-nose" ,python-nose)
100 ("python-pytest" ,python-pytest)))
555f3d15 101 (home-page "https://www.sphinx-doc.org")
9d0c291e
MB
102 (synopsis "Python documentation generator")
103 (description "Sphinx is a tool that makes it easy to create documentation
104for Python projects or other documents consisting of multiple reStructuredText
105sources.")
50bb74d0 106 (license license:bsd-2)
a60be5c5
RW
107 (properties `((python2-variant . ,(delay python2-sphinx))))))
108
109;; Sphinx 2 does not support Python 2, so we stick with this older version here.
110(define-public python2-sphinx
111 (let ((base (package-with-python2 (strip-python2-variant python-sphinx))))
112 (package
113 (inherit base)
114 (version "1.7.7")
115 (source (origin
116 (method url-fetch)
117 (uri (pypi-uri "Sphinx" version))
118 (sha256
119 (base32
120 "0pkkbfj7cl157q550gcs45am5y78ps0h7q6455d64s1zmw01jlvi"))))
121 (arguments
122 (substitute-keyword-arguments (package-arguments base)
123 ((#:phases phases)
124 `(modify-phases ,phases
125 (add-before 'check 'disable-broken-tests
126 (lambda _
127 (for-each delete-file
128 ;; These tests are broken when using Python2:
129 ;; <https://github.com/sphinx-doc/sphinx/issues/4710>.
130 '("tests/test_api_translator.py"
131 "tests/test_setup_command.py"
132 ;; This one fails for unknown reasons.
133 "tests/test_correct_year.py"))))))))
134 (native-inputs `(("python2-mock" ,python2-mock)
135 ("python2-enum34" ,python2-enum34)
136 ,@(package-native-inputs base)))
137 ;; Sphinx 2 has some dependencies that do not support Python 2, so
138 ;; we keep our own propagated-inputs here instead of inheriting.
139 (propagated-inputs
140 `(("python2-pytz" ,python2-pytz)
141 ("python2-typing" ,python2-typing)
142 ("python2-imagesize" ,python2-imagesize)
143 ("python2-sphinx-alabaster-theme" ,python2-sphinx-alabaster-theme)
144 ("python2-babel" ,python2-babel)
145 ("python2-snowballstemmer" ,python2-snowballstemmer)
146 ("python2-docutils" ,python2-docutils-0.14)
147 ("python2-jinja2" ,python2-jinja2)
148 ("python2-packaging" ,python2-packaging)
149 ("python2-pygments" ,python2-pygments)
150 ("python2-requests" ,python2-requests)
151 ("python2-six" ,python2-six)
152 ("python2-sphinxcontrib-websupport" ,python2-sphinxcontrib-websupport))))))
9d0c291e 153
bc2a3f7c
MB
154(define-public python-sphinxcontrib-applehelp
155 (package
156 (name "python-sphinxcontrib-applehelp")
f49b8c14 157 (version "1.0.2")
bc2a3f7c
MB
158 (source (origin
159 (method url-fetch)
160 (uri (pypi-uri "sphinxcontrib-applehelp" version))
161 (sha256
162 (base32
f49b8c14 163 "0n5wrn4l7x6gxvi1g7c6y72hkxgc223axz1jykipaxhfr1g76wm0"))))
bc2a3f7c
MB
164 (build-system python-build-system)
165 (arguments
166 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
167 (home-page "https://github.com/sphinx-doc/sphinxcontrib-applehelp")
168 (synopsis "Sphinx extension for creating Apple help books")
169 (description
170 "@code{sphinxcontrib-applehelp} is a Sphinx extension which outputs
171Apple help books.")
172 (license license:bsd-2)))
173
bcb22b36
RW
174(define-public python-sphinx-copybutton
175 (package
176 (name "python-sphinx-copybutton")
8d45404e 177 (version "0.2.6")
bcb22b36
RW
178 (source
179 (origin
180 (method url-fetch)
181 (uri (pypi-uri "sphinx-copybutton" version))
182 (sha256
183 (base32
8d45404e 184 "0ny9jpygj93z8jyjpi4v6jjz90pmns74s389wq16igzzq2mpgfjm"))))
bcb22b36 185 (build-system python-build-system)
8d45404e
BG
186 (arguments
187 `(#:tests? #f)) ; XXX: Check requires network access.
188 (propagated-inputs
189 `(("python-flit" ,python-flit)
190 ("python-setuptools" ,python-setuptools)
191 ("python-sphinx" ,python-sphinx)
192 ("python-wheel" ,python-wheel)))
bcb22b36
RW
193 (home-page "https://github.com/choldgraf/sphinx-copybutton")
194 (synopsis "Sphinx extension to add \"copy\" buttons to code blocks")
195 (description
196 "This package provides a small sphinx extension to add \"copy\" buttons
197to code blocks.")
198 (license license:expat)))
199
62ad0c8b
MB
200(define-public python-sphinxcontrib-devhelp
201 (package
202 (name "python-sphinxcontrib-devhelp")
ccac5118 203 (version "1.0.2")
62ad0c8b
MB
204 (source (origin
205 (method url-fetch)
206 (uri (pypi-uri "sphinxcontrib-devhelp" version))
207 (sha256
208 (base32
ccac5118 209 "1r1qngsbjqbg4rj93kpj44qqy7n4x5khldkr0c3ffhlnggx1lzzz"))))
62ad0c8b
MB
210 (build-system python-build-system)
211 (arguments
212 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
213 (home-page "https://github.com/sphinx-doc/sphinxcontrib-devhelp")
214 (synopsis "Sphinx extension for creating Devhelp documents")
215 (description
216 "@code{sphinxcontrib-devhelp} is a Sphinx extension which outputs
217@url{Devhelp,https://wiki.gnome.org/Apps/Devhelp} documents.")
218 (license license:bsd-2)))
219
a818a34f
RW
220(define-public python-sphinxcontrib-github-alt
221 (package
222 (name "python-sphinxcontrib-github-alt")
223 (version "1.2")
224 (source
225 (origin
226 (method url-fetch)
227 (uri (pypi-uri "sphinxcontrib_github_alt" version))
228 (sha256
229 (base32
230 "1x9af78vamjjcdrrhiah3wg613jv7gm8yh9vvqfrmf4vam6mimyg"))))
231 (build-system python-build-system)
232 (propagated-inputs
233 `(("python-docutils" ,python-docutils)
234 ("python-sphinx" ,python-sphinx)))
235 (home-page "https://github.com/jupyter/sphinxcontrib_github_alt")
236 (synopsis "Link to GitHub pages from Sphinx docs")
237 (description
238 "This package lets you link to GitHub issues, pull requests, commits and
239users from Sphinx docs.")
240 (license license:bsd-2)))
241
72f278a0
MB
242(define-public python-sphinxcontrib-htmlhelp
243 (package
244 (name "python-sphinxcontrib-htmlhelp")
25b576a9 245 (version "1.0.3")
72f278a0
MB
246 (source (origin
247 (method url-fetch)
248 (uri (pypi-uri "sphinxcontrib-htmlhelp" version))
249 (sha256
250 (base32
25b576a9 251 "16v5jdnibwrqjdr5aqchgyzpwy3rgamwhdf4kidv5nxj65zbpxg8"))))
72f278a0
MB
252 (build-system python-build-system)
253 (arguments
254 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
255 (home-page "https://github.com/sphinx-doc/sphinxcontrib-htmlhelp")
35fc0f4c 256 (synopsis "Sphinx extension for rendering HTML help files")
72f278a0
MB
257 (description
258 "@code{sphinxcontrib-htmlhelp} is a Sphinx extension which renders
259HTML help files.")
260 (license license:bsd-2)))
261
67be8943
MB
262(define-public python-sphinxcontrib-jsmath
263 (package
264 (name "python-sphinxcontrib-jsmath")
265 (version "1.0.1")
266 (source (origin
267 (method url-fetch)
268 (uri (pypi-uri "sphinxcontrib-jsmath" version))
269 (sha256
270 (base32
271 "1f64w19j33sp151jimibraw6qrbhd5gxy8hs3797w9478m55x4m9"))))
272 (build-system python-build-system)
273 (arguments
274 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
275 (home-page "https://github.com/sphinx-doc/sphinxcontrib-jsmath")
276 (synopsis "Sphinx extension to render math equations")
277 (description
278 "@code{sphinxcontrib-jsmath} is a Sphinx extension which renders display
279math in HTML via JavaScript.")
774520df 280 (license license:bsd-2)))
67be8943 281
9d0c291e
MB
282(define-public python-sphinxcontrib-newsfeed
283 (package
284 (name "python-sphinxcontrib-newsfeed")
285 (version "0.1.4")
286 (source (origin
287 (method url-fetch)
288 (uri (pypi-uri "sphinxcontrib-newsfeed" version))
289 (sha256
290 (base32
291 "1d7gam3mn8v4in4p16yn3v10vps7nnaz6ilw99j4klij39dqd37p"))))
292 (arguments '(#:tests? #f)) ; No tests.
293 (build-system python-build-system)
294 (propagated-inputs
295 `(("python-sphinx" ,python-sphinx)))
296 (synopsis "News Feed extension for Sphinx")
297 (description "Sphinxcontrib-newsfeed is an extension for adding a simple
298Blog, News or Announcements section to a Sphinx website.")
299 (home-page "https://bitbucket.org/prometheus/sphinxcontrib-newsfeed")
300 (license license:bsd-2)))
301
302(define-public python-sphinxcontrib-programoutput
303 (package
304 (name "python-sphinxcontrib-programoutput")
e2734fec 305 (version "0.15")
9d0c291e
MB
306 (source (origin
307 (method url-fetch)
308 (uri (pypi-uri "sphinxcontrib-programoutput" version))
309 (sha256
310 (base32
e2734fec 311 "155bz0z2cz544pphkd3nk7ph83mz7nn0ql135kzi62kqmd75ppc0"))))
9d0c291e
MB
312 (build-system python-build-system)
313 (arguments
b45aafd5 314 ;; FIXME: Many tests are failing.
9d0c291e
MB
315 '(#:tests? #f))
316 (propagated-inputs
317 `(("python-sphinx" ,python-sphinx)))
318 (synopsis "Sphinx extension to include program output")
319 (description "A Sphinx extension to literally insert the output of arbitrary
320commands into documents, helping you to keep your command examples up to date.")
b45aafd5 321 (home-page "https://github.com/NextThought/sphinxcontrib-programoutput")
9d0c291e
MB
322 (license license:bsd-2)))
323
324(define-public python2-sphinxcontrib-programoutput
325 (package-with-python2 python-sphinxcontrib-programoutput))
326
6eceb2d4
MB
327(define-public python-sphinxcontrib-qthelp
328 (package
329 (name "python-sphinxcontrib-qthelp")
99533beb 330 (version "1.0.3")
6eceb2d4
MB
331 (source (origin
332 (method url-fetch)
333 (uri (pypi-uri "sphinxcontrib-qthelp" version))
334 (sha256
335 (base32
99533beb 336 "0wjsp96d262shzkx7pb7pra7mmf0j8c5rz56i6x0vdsqw1z7ccsc"))))
6eceb2d4
MB
337 (build-system python-build-system)
338 (arguments
339 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
340 (home-page "https://github.com/sphinx-doc/sphinxcontrib-qthelp")
341 (synopsis "Sphinx extension to output QtHelp documents")
342 (description
343 "@code{sphinxcontrib-qthelp} is a Sphinx extension which outputs QtHelp
344documents.")
345 (license license:bsd-2)))
346
c5c55a9f
MB
347(define-public python-sphinxcontrib-serializinghtml
348 (package
349 (name "python-sphinxcontrib-serializinghtml")
11be1573 350 (version "1.1.4")
c5c55a9f
MB
351 (source (origin
352 (method url-fetch)
353 (uri (pypi-uri "sphinxcontrib-serializinghtml" version))
354 (sha256
355 (base32
11be1573 356 "1g3pbx0g88zd9xzcrbaypa2k60axrh92vf5j76wsk0p9hv6fr87a"))))
c5c55a9f
MB
357 (build-system python-build-system)
358 (arguments
359 `(#:tests? #f)) ;XXX: circular dependency on Sphinx
360 (home-page "https://github.com/sphinx-doc/sphinxcontrib-serializinghtml")
361 (synopsis "Sphinx extension to serialize HTML files")
362 (description
363 "@code{sphinxcontrib-serializinghtml} is a Sphinx extension which outputs
364\"serialized\" HTML files.")
365 (license license:bsd-2)))
366
9d0c291e
MB
367(define-public python-sphinxcontrib-svg2pdfconverter
368 (package
369 (name "python-sphinxcontrib-svg2pdfconverter")
76c83e33 370 (version "1.0.1")
9d0c291e
MB
371 (source (origin
372 (method url-fetch)
373 (uri (pypi-uri "sphinxcontrib-svg2pdfconverter" version))
374 (sha256
375 (base32
76c83e33 376 "1hhaxmqc7wh8gnyw5jaqckliknvk0p21y12wk3bdmncgkaf9ar8f"))))
9d0c291e
MB
377 (build-system python-build-system)
378 (propagated-inputs
379 `(("python-sphinx" ,python-sphinx)))
2564081c 380 (home-page "https://github.com/missinglinkelectronics/sphinxcontrib-svg2pdfconverter")
9d0c291e 381 (synopsis "Sphinx SVG to PDF converter extension")
f80d3442
BG
382 (description "A Sphinx extension to convert SVG images to PDF in case the
383builder does not support SVG images natively (e.g. LaTeX).")
f3c00bd1 384 (license license:bsd-2)))
9d0c291e
MB
385
386(define-public python-sphinxcontrib-websupport
387 (package
388 (name "python-sphinxcontrib-websupport")
18d59640 389 (version "1.2.0")
9d0c291e
MB
390 (source (origin
391 (method url-fetch)
392 (uri (pypi-uri "sphinxcontrib-websupport" version))
393 (sha256
394 (base32
18d59640 395 "1smma7r0rhwcmbfvvkfs5djfz1qm8wbpcvp084ca6dmw2b9zplxs"))))
9d0c291e
MB
396 (build-system python-build-system)
397 (arguments
398 ;; FIXME: Tests depend on Sphinx, which depends on this.
399 `(#:tests? #f))
b549a053 400 (home-page "https://sphinx-doc.org/")
9d0c291e
MB
401 (synopsis "Sphinx API for web applications")
402 (description "This package provides a Python API to easily integrate
403Sphinx documentation into your web application. It provides tools to
404integrate Sphinx documents in web templates and to handle searches.")
405 (license license:bsd-3)))
406
407(define-public python2-sphinxcontrib-websupport
408 (package-with-python2 python-sphinxcontrib-websupport))
409
410(define-public python-sphinx-gallery
411 (package
412 (name "python-sphinx-gallery")
51e85395
VM
413 (version "0.9.0")
414 (source
415 (origin
416 (method url-fetch)
417 (uri (pypi-uri "sphinx-gallery" version))
418 (sha256
419 (base32 "14zyhr7m92nafhhnzfvnbgkf5m91krd9mjyi24zn59bjq6zyr8hl"))))
9d0c291e
MB
420 (build-system python-build-system)
421 (arguments
51e85395
VM
422 `(#:phases
423 (modify-phases %standard-phases
424 (add-before 'check 'writable-files-for-tests
425 (lambda _
426 (for-each make-file-writable (find-files "."))))
427 (replace 'check
428 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
429 (when tests?
430 (add-installed-pythonpath inputs outputs)
431 (invoke "python" "-m" "pytest" "--pyargs" "sphinx_gallery" "-k"
432 (string-append
433 ;; These tests require online data.
434 "not test_embed_code_links_get_data"
435 " and not test_run_sphinx"
436 ;; AssertionError.
437 " and not test_embed_links_and_styles"))))))))
9d0c291e 438 (native-inputs
51e85395
VM
439 `(("python-joblib" ,python-joblib)
440 ("python-matplotlib" ,python-matplotlib)
441 ("python-numpy" ,python-numpy)
442 ("python-pillow" ,python-pillow)
443 ("python-pytest" ,python-pytest)
444 ("python-pytest-cov" ,python-pytest-cov)
445 ("python-sphinx" ,python-sphinx)))
446 (home-page "https://sphinx-gallery.github.io/stable/index.html")
9d0c291e
MB
447 (synopsis "Generate an examples gallery automatically")
448 (description
449 "@code{sphinx_gallery} is a Sphinx extension that builds an HTML version
450from any set of Python scripts and puts it into an examples gallery.")
451 (license license:bsd-3)))
452
9d0c291e
MB
453(define-public python-sphinx-me
454 (package
455 (name "python-sphinx-me")
456 (version "0.3")
457 (source
458 (origin
459 (method url-fetch)
460 (uri (pypi-uri "sphinx-me" version))
461 (sha256
462 (base32
463 "06jzgp213zihnvpcy2y5jy3ykid3apc2ncp2pg6a2g05lhiziglq"))))
464 (build-system python-build-system)
465 (home-page "https://github.com/stephenmcd/sphinx-me")
466 (synopsis "Create a Sphinx documentation shell")
467 (description
468 "Create a Sphinx documentation shell for your project and include the
469README file as the documentation index. It handles extracting the required
470meta data such as the project name, author and version from your project for
471use in your Sphinx docs.")
472 (license license:bsd-2)))
473
474(define-public python2-sphinx-me
475 (package-with-python2 python-sphinx-me))
476
477(define-public python-sphinx-repoze-autointerface
478 (package
479 (name "python-sphinx-repoze-autointerface")
480 (version "0.8")
481 (source (origin
482 (method url-fetch)
483 (uri (pypi-uri "repoze.sphinx.autointerface" version))
484 (sha256
485 (base32
486 "08ycivzf7bh4a1zcyp31hbyqs1b2c9r26raa3vxjwwmbfqr3iw4f"))))
487 (build-system python-build-system)
488 (arguments '(#:tests? #f)) ; No tests.
489 (propagated-inputs
490 `(("python-sphinx" ,python-sphinx)
491 ("python-zope-interface" ,python-zope-interface)))
492 (synopsis "Auto-generate Sphinx API docs from Zope interfaces")
493 (description "This package defines an extension for the Sphinx documentation
494system. The extension allows generation of API documentation by
495introspection of @code{zope.interface} instances in code.")
496 (home-page "https://github.com/repoze/repoze.sphinx.autointerface")
497 (license license:repoze)))
498
499(define-public python2-sphinx-repoze-autointerface
500 (package-with-python2 python-sphinx-repoze-autointerface))
501
502(define-public python-sphinx-alabaster-theme
503 (package
504 (name "python-sphinx-alabaster-theme")
505 (version "0.7.12")
506 (source (origin
507 (method url-fetch)
508 (uri (pypi-uri "alabaster" version))
509 (sha256
510 (base32
511 "00nwwjj2d2ym4s2kk217x7jkx1hnczc3fvm8yxbqmsp6b0nxfqd6"))))
512 (build-system python-build-system)
513 (propagated-inputs
514 `(("python-pygments" ,python-pygments)))
515 (home-page "https://alabaster.readthedocs.io/")
516 (synopsis "Configurable sidebar-enabled Sphinx theme")
517 (description "Alabaster is a visually (c)lean, responsive, configurable
518theme for the Sphinx documentation system. It's the default theme of Sphinx.")
519 (license license:bsd-3)))
520
521(define-public python2-sphinx-alabaster-theme
522 (package-with-python2 python-sphinx-alabaster-theme))
523
e5c1348a
NG
524(define-public python-sphinx-argparse
525 (package
526 (name "python-sphinx-argparse")
527 (version "0.2.5")
528 (source
529 (origin
530 (method url-fetch)
531 (uri (pypi-uri "sphinx-argparse" version))
532 (sha256
533 (base32 "05wc8f5hb3jsg2vh2jf7jsyan8d4i09ifrz2c8fp6f7x1zw9iav0"))))
534 (build-system python-build-system)
535 (propagated-inputs
536 `(("python-sphinx" ,python-sphinx)))
537 (native-inputs
538 `(("python-commonmark" ,python-commonmark)
539 ("python-pytest" ,python-pytest)
540 ("python-sphinx-rtd-theme" ,python-sphinx-rtd-theme)))
541 (home-page "https://github.com/ribozz/sphinx-argparse")
542 (synopsis "Sphinx extension for documenting argparse commands and options")
543 (description
544 "This package is a sphinx extension that automatically documents
545argparse commands and options")
546 (license license:expat)))
547
9d0c291e
MB
548(define-public python-sphinx-cloud-sptheme
549 (package
550 (name "python-sphinx-cloud-sptheme")
551 (version "1.8.0")
552 (source (origin
553 (method url-fetch)
554 (uri (pypi-uri "cloud_sptheme" version))
555 (sha256
556 (base32
557 "1dniqb6a39yh786f86c4jn666rwnyi1jvzn4616zhcchb7sfdshd"))))
558 (build-system python-build-system)
559 ;; FIXME: The 'pypi' release archive does not contain tests.
560 (arguments '(#:tests? #f))
561 (native-inputs
562 `(("python-sphinx" ,python-sphinx)))
563 (home-page "https://bitbucket.org/ecollins/cloud_sptheme")
564 (synopsis "'Cloud' theme for Sphinx documenter")
565 (description "This package contains the \"Cloud\" theme for Sphinx and some
566related extensions.")
567 (license license:bsd-3)))
568
569(define-public python2-sphinx-cloud-sptheme
570 (package-with-python2 python-sphinx-cloud-sptheme))
571
572(define-public python-guzzle-sphinx-theme
573 (package
574 (name "python-guzzle-sphinx-theme")
575 (version "0.7.11")
576 (source
577 (origin
578 (method url-fetch)
579 (uri (pypi-uri "guzzle_sphinx_theme" version))
580 (sha256
581 (base32
582 "1rnkzrrsbnifn3vsb4pfaia3nlvgvw6ndpxp7lzjrh23qcwid34v"))))
583 (build-system python-build-system)
584 (propagated-inputs
585 `(("python-sphinx" ,python-sphinx)))
586 (home-page "https://github.com/guzzle/guzzle_sphinx_theme")
587 (synopsis "Sphinx theme used by Guzzle")
588 (description "This package provides guzzle_sphinx_theme, a theme for the
589Sphinx documentation system, used by @uref{http://docs.guzzlephp.org, Guzzle}
590and several other projects.")
591 (license license:expat)))
592
593(define-public python2-guzzle-sphinx-theme
594 (package-with-python2 python-guzzle-sphinx-theme))
595
596(define-public python-sphinx-rtd-theme
597 (package
598 (name "python-sphinx-rtd-theme")
599 (version "0.2.4")
600 (source
601 (origin
602 (method url-fetch)
603 (uri (pypi-uri "sphinx_rtd_theme" version))
604 (sha256
605 (base32
606 "05rlhjzdyapr2w74jjs7mrm8hi69qskcr5vya9f9drpsys7lpxrd"))))
607 (build-system python-build-system)
608 (arguments '(#:tests? #f)) ; No tests.
609 (propagated-inputs
610 `(("python-sphinx" ,python-sphinx)))
611 (home-page "https://github.com/snide/sphinx_rtd_theme/")
612 (synopsis "ReadTheDocs.org theme for Sphinx")
613 (description "A theme for Sphinx used by ReadTheDocs.org.")
614 (license license:expat)))
615
616(define-public python2-sphinx-rtd-theme
617 (package-with-python2 python-sphinx-rtd-theme))
68f0de01
SB
618
619(define-public python-breathe
620 (package
621 (name "python-breathe")
488fc3d2 622 (version "4.30.0")
68f0de01
SB
623 (source
624 (origin
625 (method url-fetch)
626 (uri (pypi-uri "breathe" version))
627 (sha256
628 (base32
488fc3d2 629 "055h95fkdld7s49878fqjx1nri1drj1czc184vrb7i60mf2yqg9n"))))
68f0de01
SB
630 (build-system python-build-system)
631 (propagated-inputs
632 `(("python-docutils" ,python-docutils)
68f0de01
SB
633 ("python-sphinx" ,python-sphinx)))
634 (home-page "https://github.com/michaeljones/breathe")
635 (synopsis "ReStructuredText and Sphinx bridge to Doxygen")
636 (description "This package is an extension to reStructuredText and Sphinx
637to be able to read and render the Doxygen xml output.")
638 (license license:bsd-3)))
90ee17cd
AT
639
640(define-public python-sphinx-intl
641 (package
642 (name "python-sphinx-intl")
728fdd83 643 (version "2.0.1")
90ee17cd
AT
644 (source
645 (origin
646 (method url-fetch)
647 (uri (pypi-uri "sphinx-intl" version))
648 (sha256
728fdd83 649 (base32 "1d1q0sanjp4nkfvhsxi75zf3xjyyi8nzxvl3v7l0jy9ld70nwnmj"))))
90ee17cd
AT
650 (build-system python-build-system)
651 (propagated-inputs
652 `(("python-sphinx" ,python-sphinx)
653 ("python-click" ,python-click)))
654 (home-page "https://github.com/sphinx-doc/sphinx-intl")
655 (synopsis
656 "Sphinx utility that makes it easy to translate and to apply translation")
657 (description
658 "A utility tool that provides several features that make it easy to
659translate and to apply translation to Sphinx generated document.")
660 (license license:bsd-2)))
e9f93cd5
RW
661
662(define-public python-sphinx-autobuild
663 (package
664 (name "python-sphinx-autobuild")
665 (version "0.7.1")
666 (source
667 (origin
668 (method url-fetch)
669 (uri (pypi-uri "sphinx-autobuild" version))
670 (sha256
671 (base32
672 "0kn753dyh3b1s0h77lbk704niyqc7bamvq6v3s1f6rj6i20qyf36"))))
673 (build-system python-build-system)
674 (arguments
675 `(#:phases
676 (modify-phases %standard-phases
677 ;; See https://github.com/GaretJax/sphinx-autobuild/pull/72
678 (add-after 'unpack 'use-later-port-for
679 (lambda _
680 (substitute* "requirements.txt"
681 (("port_for==.*") "port_for\n"))
682 #t))
683 (delete 'check)
684 (add-after 'install 'check
685 (lambda* (#:key inputs outputs tests? #:allow-other-keys)
686 (when tests?
687 (add-installed-pythonpath inputs outputs)
688 (invoke "pytest" "-v"))
689 #t)))))
690 (propagated-inputs
691 `(("python-argh" ,python-argh)
692 ("python-livereload" ,python-livereload)
693 ("python-pathtools" ,python-pathtools)
694 ("python-port-for" ,python-port-for)
695 ("python-pyyaml" ,python-pyyaml)
696 ("python-tornado" ,python-tornado)
697 ("python-watchdog" ,python-watchdog)))
698 (native-inputs
699 `(("python-pytest" ,python-pytest)))
700 (home-page "https://github.com/GaretJax/sphinx-autobuild")
701 (synopsis "Rebuild Sphinx documentation when a change is detected")
702 (description
703 "This package lets you watch a Sphinx directory and rebuild the
704documentation when a change is detected. It also includes a livereload
705enabled web server.")
706 (license license:expat)))
83ade5bf 707
207aa62e
EB
708(define-public python-sphinx-autodoc-typehints
709 (package
710 (name "python-sphinx-autodoc-typehints")
711 (version "1.11.1")
712 (source
713 (origin
714 (method url-fetch)
715 (uri (pypi-uri "sphinx-autodoc-typehints" version))
716 (sha256
717 (base32
718 "086v9mg21pvfx0lfqjx2xf36hnzrsripfg345xi59f7xwb9scjr4"))))
719 (build-system python-build-system)
720 (propagated-inputs
721 `(("python-setuptools-scm" ,python-setuptools-scm)
722 ("python-sphinx" ,python-sphinx)))
723 (native-inputs
724 `(("python-dataclasses" ,python-dataclasses)
725 ("python-pytest" ,python-pytest)
726 ("python-sphinx" ,python-sphinx)
727 ("python-sphobjinv" ,python-sphobjinv)
728 ("python-typing-extensions" ,python-typing-extensions)))
729 (home-page "https://pypi.org/project/sphinx-autodoc-typehints/")
730 (synopsis "Type hints for the Sphinx autodoc extension")
731 (description "This extension allows you to use Python 3 annotations for
732documenting acceptable argument types and return value types of functions.")
733 (license license:expat)))
734
83ade5bf
GL
735(define-public python-nbsphinx
736 (package
737 (name "python-nbsphinx")
738 (version "0.7.1")
739 (source
740 (origin
741 (method url-fetch)
742 (uri (pypi-uri "nbsphinx" version))
743 (sha256
744 (base32
745 "0j56bxdj08vn3q1804qwb1ywhga1mdg1awgm7i64wfpfwi8df2zm"))))
746 (build-system python-build-system)
747 (propagated-inputs
748 `(("python-docutils" ,python-docutils)
749 ("python-jinja2" ,python-jinja2)
750 ("python-nbconvert" ,python-nbconvert)
751 ("python-nbformat" ,python-nbformat)
752 ("python-sphinx" ,python-sphinx)
753 ("python-traitlets" ,python-traitlets)))
754 (home-page "https://nbsphinx.readthedocs.io/")
755 (synopsis "Jupyter Notebook Tools for Sphinx")
756 (description "@code{python-nbsphinx} is a Sphinx extension that
757provides a source parser for @code{*.ipynb} files. Custom Sphinx
758directives are used to show Jupyter Notebook code cells (and of course
759their results) in both HTML and LaTeX output. Un-evaluated notebooks
760- i.e. notebooks without stored output cells - will be automatically
761executed during the Sphinx build process.")
762 (license license:expat)))
b1572018
EB
763
764(define-public python-sphobjinv
765 (package
766 (name "python-sphobjinv")
767 (version "2.0.1")
768 (source
769 (origin
770 (method url-fetch)
771 (uri (pypi-uri "sphobjinv" version))
772 (sha256
773 (base32
1ed435bf 774 "126lgm54c94ay3fci512ap4l607gak90pbz0fk98syxvj5izrrzx"))))
b1572018
EB
775 (build-system python-build-system)
776 (propagated-inputs
777 `(("python-attrs" ,python-attrs)
1ed435bf 778 ("python-certifi" ,python-certifi)
b1572018
EB
779 ("python-fuzzywuzzy" ,python-fuzzywuzzy)
780 ("python-jsonschema" ,python-jsonschema)
781 ("python-levenshtein" ,python-levenshtein)))
782 (home-page "https://github.com/bskinn/sphobjinv")
783 (synopsis "Sphinx cross-reference tool")
784 (description "Sphinx objects.inv inspection/manipulation tool.")
785 (license license:expat)))