Jupyter Notebook Tools for Sphinx#
nbsphinx is a Sphinx extension that provides a source parser for
*.ipynb files.
Custom Sphinx directives are used to show Jupyter Notebook code cells (and of
course their results) in both HTML and LaTeX output.
Un-evaluated notebooks – i.e. notebooks without stored output cells – will be
automatically executed during the Sphinx build process.
- Quick Start:
Install
nbsphinxEdit your
conf.pyand add'nbsphinx'toextensions.Edit your
index.rstand add the names of your*.ipynbfiles to thetoctree.Run Sphinx!
- Online documentation (and example of use):
- Source code repository (and issue tracker):
- License:
MIT – see the file
LICENSEfor details.
All of the following content was generated from Jupyter notebooks, except for the sections Normal reStructuredText Files, Contributing, References and Version History, which were generated from Sphinx’s built-in reStructuredText format. The sections Custom Notebook Formats, Dummy Notebook 2 for Gallery and Using Markdown Files are using alternative storage formats for Jupyter notebooks, see Custom Notebook Formats for details.
click here to see full table of contents
- Installation
- Usage
- Configuration
- Sphinx Configuration Values
nbsphinxConfiguration Valuesnbsphinx_allow_errorsnbsphinx_assume_equationsnbsphinx_codecell_lexernbsphinx_custom_formatsnbsphinx_epilognbsphinx_executenbsphinx_execute_argumentsnbsphinx_input_promptnbsphinx_kernel_namenbsphinx_output_promptnbsphinx_prolognbsphinx_prompt_widthnbsphinx_requirejs_optionsnbsphinx_requirejs_pathnbsphinx_responsive_widthnbsphinx_thumbnailsnbsphinx_timeoutnbsphinx_widgets_optionsnbsphinx_widgets_path
- Markdown Cells
- Code Cells
- Raw Cells
- Hidden Cells
- Controlling Notebook Execution
- Prolog and Epilog
- Custom Notebook Formats
- Notebooks in Sub-Directories
- Creating Thumbnail Galleries
- Using
toctreeIn A Notebook - Custom CSS
- Normal reStructuredText Files
- Using Markdown Files
- External Links
- Contributing
- References
- Version History
There is also An Orphan Notebook (HTML Only), just for the sake of it.
How To Navigate This Site
Use the next and previous links at the top and the bottom of each page to flip through the pages. Alternatively, you can use the right and left arrow keys on your keyboard. Some additional keyboard shortcuts are provided via the accesskey feature: n next, p previous, u up (= to the parent page), i index, s search and m menu (= open/close sidebar).
Click on the hamburger button in the topbar to open and close the sidebar. The width of the sidebar can be adjusted by dragging its border. Click on the title in the topbar to scroll to the top of the page, if already at the top, go “up” to the parent page (eventually ending up on this very page).
On touch-enabled devices: Tap at the top of the page to show the topbar (if it was scrolled away); swipe from the left edge to show the sidebar, swipe towards the left to hide it.