Skip to content

Commit

Permalink
Re-include missing notebooks (#206)
Browse files Browse the repository at this point in the history
The documentation includes some "template" jupyter notebooks, which need to be compiled using `scripts/make_notebook.py` into a teaching + solution version.

This did not happen on readthedocs, and @giovannipizzi accidentally removed the compiled version of these notebooks from the git repository.
This PR now causes them to be built on RTD.
  • Loading branch information
giovannipizzi committed Apr 16, 2020
1 parent f13ea45 commit de29b08
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
4 changes: 1 addition & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ env:
matrix:
- BUILD: docs
TARGET: html
SPHINXOPTS: -W
SPHINXOPTS: -nW
- BUILD: docs
TARGET: latexpdf
- BUILD: pre-commit
Expand All @@ -35,8 +35,6 @@ install:
script:
- >
if [ "$BUILD" == "docs" ]; then
# -C docs: switch to docs/ directory
make -C docs pre-docs
make -C docs $TARGET
else
pre-commit install
Expand Down
12 changes: 12 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
from __future__ import print_function
from __future__ import absolute_import

import os
import subprocess

# -- General configuration -----------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
Expand Down Expand Up @@ -352,3 +355,12 @@ def setup(app):
intersphinx_mapping = {
'aiida': ('http://aiida-core.readthedocs.org/en/latest/', None)
}

# Compile all things needed before building the docs
# For instance, convert the notebook templates to actual tutorial and solution versions
print(
subprocess.check_output([
'make', '-C',
os.path.dirname(os.path.realpath(__file__)), 'pre-docs'
],
universal_newlines=True))

0 comments on commit de29b08

Please sign in to comment.