Skip to content

Commit

Permalink
Merge pull request #379 from AurelienJaquier/readthedocs
Browse files Browse the repository at this point in the history
also make readthedocs convert examples for docs
  • Loading branch information
AurelienJaquier authored Apr 25, 2024
2 parents b8a1a6a + 2cddd26 commit 14b194f
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 8 deletions.
5 changes: 5 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ build:
os: ubuntu-22.04
tools:
python: "3.10"
jobs:
pre_build:
cd docs
sh examples_to_rst.sh
cd -

python:
# Install our python package before building the docs
Expand Down
6 changes: 6 additions & 0 deletions docs/examples_to_rst.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
jupyter nbconvert --to rst ../examples/sonata-network/sonata-network.ipynb
jupyter nbconvert --to rst ../examples/nmc-portal/L5TTPC2.ipynb
cp ../examples/sonata-network/sonata-network.rst source/
cp -r ../examples/sonata-network/sonata-network_files source/
cp ../examples/nmc-portal/L5TTPC2.rst source/nmc-portal.rst
cp -r ../examples/nmc-portal/L5TTPC2_files source/
6 changes: 4 additions & 2 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@

# General information about the project.
project = u'eFEL'
copyright = u'2015-2024, BBP, EPFL'
# do not define copyright here, in order to use the default Blue Brain project copyright
# copyright = u'2015-2024, BBP, EPFL'

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
Expand Down Expand Up @@ -108,7 +109,8 @@

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'sphinx_rtd_theme'
html_theme = "sphinx-bluebrain-theme"
# html_theme = 'sphinx_rtd_theme'
# html_theme = 'haiku-bbp'

# Theme options are theme-specific and customize the look and feel of a theme
Expand Down
1 change: 1 addition & 0 deletions requirements_docs.txt
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

sphinx>=7.2.6
sphinx-bluebrain-theme
sphinx_rtd_theme>=2.0.0
sphinx-autobuild>=2021.3.14
sphinx-autorun>=1.1.1
Expand Down
8 changes: 2 additions & 6 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -76,15 +76,11 @@ allowlist_externals =
make
jupyter
cp
sh
changedir = docs

commands =
jupyter nbconvert --to rst ../examples/sonata-network/sonata-network.ipynb
jupyter nbconvert --to rst ../examples/nmc-portal/L5TTPC2.ipynb
cp ../examples/sonata-network/sonata-network.rst source/
cp -r ../examples/sonata-network/sonata-network_files source/
cp ../examples/nmc-portal/L5TTPC2.rst source/nmc-portal.rst
cp -r ../examples/nmc-portal/L5TTPC2_files source/
sh examples_to_rst.sh
# build the docs to see if it builds fine
make html SPHINXOPTS=-W
# make sure the feature names and units are up-to-date
Expand Down

0 comments on commit 14b194f

Please sign in to comment.