1{ lib
2, buildPythonPackage
3, fetchFromGitHub
4
5# build-system
6, setuptools
7
8# documentation build dependencies
9, sphinxHook
10# runtime dependencies
11, sphinx
12, pygments
13, docutils
14# test dependencies
15, pytest
16, beautifulsoup4
17}:
18
19buildPythonPackage rec {
20 pname = "sphinx-tabs";
21 version = "3.4.4";
22 format = "pyproject";
23
24 outputs = [ "out" "doc" ];
25
26 src = fetchFromGitHub {
27 owner = "executablebooks";
28 repo = "sphinx-tabs";
29 rev = "refs/tags/v${version}";
30 hash = "sha256-RcCADGJfwXP/U7Uws/uX+huaJzRDRUabQOnc9gqMUzM=";
31 };
32
33 postPatch = ''
34 substituteInPlace setup.py --replace 'docutils~=0.18.0' 'docutils'
35 '';
36
37 nativeBuildInputs = [
38 setuptools
39 sphinxHook
40 ];
41
42 propagatedBuildInputs = [
43 sphinx
44 pygments
45 docutils
46 ];
47
48 nativeCheckInputs = [ pytest
49 beautifulsoup4
50 ];
51
52 pythonImportsCheck = [ "sphinx_tabs" ];
53
54 meta = with lib; {
55 description = "A sphinx extension for creating tabbed content when building HTML.";
56 homepage = "https://github.com/executablebooks/sphinx-tabs";
57 license = licenses.mit;
58 maintainers = with maintainers; [ kaction ];
59 };
60}