Merge pull request #179773 from marsam/add-jupyter-book

python310Packages.jupyter-book: init at 0.13.0

Closes #132686
This commit is contained in:
Mario Rodas 2022-07-02 22:26:27 -05:00 committed by GitHub
commit 19d31fc041
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 520 additions and 2 deletions

View file

@ -0,0 +1,80 @@
{ lib
, buildPythonPackage
, fetchPypi
, pythonOlder
, flit-core
, click
, docutils
, jinja2
, jsonschema
, linkify-it-py
, myst-nb
, pyyaml
, sphinx
, sphinx-comments
, sphinx-copybutton
, sphinx-external-toc
, sphinx-jupyterbook-latex
, sphinx-design
, sphinx-thebe
, sphinx-book-theme
, sphinx-togglebutton
, sphinxcontrib-bibtex
, sphinx-multitoc-numbering
}:
buildPythonPackage rec {
pname = "jupyter-book";
version = "0.13.0";
format = "flit";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "0a956677e7bbee630dd66641c09a84091277887d6dcdd381a676f00fa9de2074";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace "jsonschema<4" "jsonschema" \
--replace "sphinx-external-toc~=0.2.3" "sphinx-external-toc" \
--replace "myst-nb~=0.13.1" "myst-nb" \
--replace "docutils>=0.15,<0.18" "docutils" \
--replace "sphinx-design~=0.1.0" "sphinx-design" \
--replace "linkify-it-py~=1.0.1" "linkify-it-py"
'';
nativeBuildInputs = [ flit-core ];
propagatedBuildInputs = [
click
docutils
jinja2
jsonschema
linkify-it-py
myst-nb
pyyaml
sphinx
sphinx-comments
sphinx-copybutton
sphinx-external-toc
sphinx-jupyterbook-latex
sphinx-design
sphinx-thebe
sphinx-book-theme
sphinx-togglebutton
sphinxcontrib-bibtex
sphinx-multitoc-numbering
];
pythonImportsCheck = [ "jupyter_book" ];
meta = with lib; {
description = "Build a book with Jupyter Notebooks and Sphinx";
homepage = "https://executablebooks.org/";
license = licenses.bsd3;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,50 @@
{ lib
, buildPythonPackage
, fetchPypi
, attrs
, click
, importlib-metadata
, nbclient
, nbformat
, pyyaml
, sqlalchemy
, tabulate
, pythonOlder
}:
buildPythonPackage rec {
pname = "jupyter-cache";
version = "0.5.0";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "87408030a4c8c14fe3f8fe62e6ceeb24c84e544c7ced20bfee45968053d07801";
};
postPatch = ''
substituteInPlace setup.cfg \
--replace "nbclient>=0.2,<0.6" "nbclient"
'';
propagatedBuildInputs = [
attrs
click
importlib-metadata
nbclient
nbformat
pyyaml
sqlalchemy
tabulate
];
pythonImportsCheck = [ "jupyter_cache" ];
meta = with lib; {
description = "A defined interface for working with a cache of jupyter notebooks";
homepage = "https://github.com/executablebooks/jupyter-cache";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,56 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, flit-core
, importlib-metadata
, ipython
, jupyter-cache
, nbclient
, myst-parser
, nbformat
, pyyaml
, sphinx
, sphinx-togglebutton
, typing-extensions
, ipykernel
}:
buildPythonPackage rec {
pname = "myst-nb";
version = "0.16.0";
format = "flit";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "9c7ab37929da72f78569a37bcccbc5d49fd679fd7935bf6c9fa36365eb58783a";
};
nativeBuildInputs = [ flit-core ];
propagatedBuildInputs = [
importlib-metadata
ipython
jupyter-cache
nbclient
myst-parser
nbformat
pyyaml
sphinx
sphinx-togglebutton
typing-extensions
ipykernel
];
pythonImportsCheck = [ "myst_nb" ];
meta = with lib; {
description = "A Jupyter Notebook Sphinx reader built on top of the MyST markdown parser";
homepage = "https://github.com/executablebooks/myst-nb";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,42 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, sphinx
, beautifulsoup4
, docutils
, packaging
}:
buildPythonPackage rec {
pname = "pydata-sphinx-theme";
version = "0.8.1";
format = "wheel";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit version format;
dist = "py3";
python = "py3";
pname = "pydata_sphinx_theme";
sha256 = "af2c99cb0b43d95247b1563860942ba75d7f1596360594fce510caaf8c4fcc16";
};
propagatedBuildInputs = [
sphinx
beautifulsoup4
docutils
packaging
];
pythonImportsCheck = [ "pydata_sphinx_theme" ];
meta = with lib; {
description = "Bootstrap-based Sphinx theme from the PyData community";
homepage = "https://github.com/pydata/pydata-sphinx-theme";
license = licenses.bsd3;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -1,4 +1,5 @@
{ lib
, stdenv
, buildPythonPackage
, cython
, ninja
@ -7,6 +8,9 @@
, fetchPypi
, gn
, pytestCheckHook
, xcodebuild
, ApplicationServices
, OpenGL
}:
buildPythonPackage rec {
@ -26,7 +30,10 @@ buildPythonPackage rec {
'build_cmd = [sys.executable, build_skia_py, "--no-fetch-gn", "--no-virtualenv", "--gn-path", "${gn}/bin/gn", build_dir]'
'';
nativeBuildInputs = [ cython ninja setuptools-scm ];
nativeBuildInputs = [ cython ninja setuptools-scm ]
++ lib.optionals stdenv.isDarwin [ xcodebuild ];
buildInputs = lib.optionals stdenv.isDarwin [ ApplicationServices OpenGL ];
propagatedBuildInputs = [ setuptools ];

View file

@ -0,0 +1,40 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, sphinx
, pydata-sphinx-theme
, pyyaml
}:
buildPythonPackage rec {
pname = "sphinx-book-theme";
version = "0.3.2";
format = "wheel";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit version format;
dist = "py3";
python = "py3";
pname = "sphinx_book_theme";
sha256 = "4aed92f2ed9d27e002eac5dce1daa8eca42dd9e6464811533c569ee156a6f67d";
};
propagatedBuildInputs = [
sphinx
pydata-sphinx-theme
pyyaml
];
pythonImportsCheck = [ "sphinx_book_theme" ];
meta = with lib; {
description = "A clean book theme for scientific explanations and documentation with Sphinx";
homepage = "https://github.com/executablebooks/sphinx-book-theme";
license = licenses.bsd3;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,26 @@
{ lib
, buildPythonPackage
, fetchPypi
, sphinx
}:
buildPythonPackage rec {
pname = "sphinx-comments";
version = "0.0.3";
src = fetchPypi {
inherit pname version;
sha256 = "00170afff27019fad08e421da1ae49c681831fb2759786f07c826e89ac94cf21";
};
propagatedBuildInputs = [ sphinx ];
pythonImportsCheck = [ "sphinx_comments" ];
meta = with lib; {
description = "Add comments and annotation to your documentation";
homepage = "https://github.com/executablebooks/sphinx-comments";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,35 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, flit-core
, sphinx
}:
buildPythonPackage rec {
pname = "sphinx-design";
version = "0.2.0";
format = "flit";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit version;
pname = "sphinx_design";
sha256 = "b148a5258061a46ee826d57ea0729260f29b4e9131d2a681545e0d4f3c0f19ee";
};
nativeBuildInputs = [ flit-core ];
propagatedBuildInputs = [ sphinx ];
pythonImportsCheck = [ "sphinx_design" ];
meta = with lib; {
description = "A sphinx extension for designing beautiful, view size responsive web components";
homepage = "https://github.com/executablebooks/sphinx-design";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,41 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, flit-core
, click
, pyyaml
, sphinx
}:
buildPythonPackage rec {
pname = "sphinx-external-toc";
version = "0.3.0";
format = "flit";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit version;
pname = "sphinx_external_toc";
sha256 = "73198636ada4b4f72f69c7bab09f0e4ce84978056dc5afa9ee51d287bec0a8ef";
};
nativeBuildInputs = [ flit-core ];
propagatedBuildInputs = [
click
pyyaml
sphinx
];
pythonImportsCheck = [ "sphinx_external_toc" ];
meta = with lib; {
description = "A sphinx extension that allows the site-map to be defined in a single YAML file";
homepage = "https://github.com/executablebooks/sphinx-external-toc";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,32 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, sphinx
, importlib-resources
}:
buildPythonPackage rec {
pname = "sphinx-jupyterbook-latex";
version = "0.4.6";
disabled = pythonOlder "3.6";
src = fetchPypi {
inherit version;
pname = "sphinx_jupyterbook_latex";
sha256 = "8ff3775b11ab4798e6e8ec983601d7aea4c3b8e8b5d28ca758578ede3a791334";
};
propagatedBuildInputs = [ sphinx ]
++ lib.optionals (pythonOlder "3.9") [ importlib-resources ];
pythonImportsCheck = [ "sphinx_jupyterbook_latex" ];
meta = with lib; {
description = "Latex specific features for jupyter book";
homepage = "https://github.com/executablebooks/sphinx-jupyterbook-latex";
license = licenses.bsd3;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,26 @@
{ lib
, buildPythonPackage
, fetchPypi
, sphinx
}:
buildPythonPackage rec {
pname = "sphinx-multitoc-numbering";
version = "0.1.3";
src = fetchPypi {
inherit pname version;
sha256 = "c9607671ac511236fa5d61a7491c1031e700e8d498c9d2418e6c61d1251209ae";
};
propagatedBuildInputs = [ sphinx ];
pythonImportsCheck = [ "sphinx_multitoc_numbering" ];
meta = with lib; {
description = "Supporting continuous HTML section numbering";
homepage = "https://github.com/executablebooks/sphinx-multitoc-numbering";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,29 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchPypi
, sphinx
}:
buildPythonPackage rec {
pname = "sphinx-thebe";
version = "0.1.2";
disabled = pythonOlder "3.6";
src = fetchPypi {
inherit pname version;
sha256 = "756f1dd6643f5abb491f8a27b22825b04f47e05c5d214bbb2e6b5d42b621b85e";
};
propagatedBuildInputs = [ sphinx ];
pythonImportsCheck = [ "sphinx_thebe" ];
meta = with lib; {
description = "Integrate interactive code blocks into your documentation with Thebe and Binder";
homepage = "https://github.com/executablebooks/sphinx-thebe";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -0,0 +1,28 @@
{ lib
, buildPythonPackage
, fetchPypi
, wheel
, sphinx
, docutils
}:
buildPythonPackage rec {
pname = "sphinx-togglebutton";
version = "0.3.1";
src = fetchPypi {
inherit pname version;
sha256 = "1f13c25c27a8ff40d6fc924d324746c0adb0dedeef40730c8a8b64ff55c6c92c";
};
propagatedBuildInputs = [ wheel sphinx docutils ];
pythonImportsCheck = [ "sphinx_togglebutton" ];
meta = with lib; {
description = "Toggle page content and collapse admonitions in Sphinx";
homepage = "https://github.com/executablebooks/sphinx-togglebutton";
license = licenses.mit;
maintainers = with maintainers; [ marsam ];
};
}

View file

@ -3262,7 +3262,9 @@ in {
fontmake = callPackage ../development/python-modules/fontmake { };
skia-pathops = callPackage ../development/python-modules/skia-pathops { };
skia-pathops = callPackage ../development/python-modules/skia-pathops {
inherit (pkgs.darwin.apple_sdk.frameworks) ApplicationServices OpenGL;
};
openstep-plist = callPackage ../development/python-modules/openstep-plist { };
@ -4607,8 +4609,12 @@ in {
jupyter = callPackage ../development/python-modules/jupyter { };
jupyter-book = callPackage ../development/python-modules/jupyter-book { };
jupyter-c-kernel = callPackage ../development/python-modules/jupyter-c-kernel { };
jupyter-cache = callPackage ../development/python-modules/jupyter-cache { };
jupyter-client = callPackage ../development/python-modules/jupyter-client { };
jupyter_console = callPackage ../development/python-modules/jupyter_console { };
@ -5672,6 +5678,8 @@ in {
mysql-connector = callPackage ../development/python-modules/mysql-connector { };
myst-nb = callPackage ../development/python-modules/myst-nb { };
myst-parser = callPackage ../development/python-modules/myst-parser { };
nad-receiver = callPackage ../development/python-modules/nad-receiver { };
@ -7249,6 +7257,8 @@ in {
pydash = callPackage ../development/python-modules/pydash { };
pydata-sphinx-theme = callPackage ../development/python-modules/pydata-sphinx-theme { };
pydbus = callPackage ../development/python-modules/pydbus { };
pydeck = callPackage ../development/python-modules/pydeck { };
@ -9976,8 +9986,24 @@ in {
sphinx-better-theme = callPackage ../development/python-modules/sphinx-better-theme { };
sphinx-book-theme = callPackage ../development/python-modules/sphinx-book-theme { };
sphinx-comments = callPackage ../development/python-modules/sphinx-comments { };
sphinx-design = callPackage ../development/python-modules/sphinx-design { };
sphinx-external-toc = callPackage ../development/python-modules/sphinx-external-toc { };
sphinx-jupyterbook-latex = callPackage ../development/python-modules/sphinx-jupyterbook-latex { };
sphinx-multitoc-numbering = callPackage ../development/python-modules/sphinx-multitoc-numbering { };
sphinx-pytest = callPackage ../development/python-modules/sphinx-pytest { };
sphinx-thebe = callPackage ../development/python-modules/sphinx-thebe { };
sphinx-togglebutton = callPackage ../development/python-modules/sphinx-togglebutton { };
sphinxcontrib-actdiag = callPackage ../development/python-modules/sphinxcontrib-actdiag { };
sphinxcontrib-apidoc = callPackage ../development/python-modules/sphinxcontrib-apidoc { };