Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update readthedocs configuration #384

Merged
merged 2 commits into from
Nov 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .readthedocs.yml → .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
# Required
version: 2

# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/conf.py
Expand Down
16 changes: 3 additions & 13 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -322,22 +322,12 @@ def run_apidoc(_):

# -- add static files----------------------------------------------------------

def setup_static_content(app):
# configure stylesheets
for sdir in html_static_path:
# add stylesheets
cssdir = os.path.join(sdir, 'css')
for cssf in glob.glob(os.path.join(cssdir, '*.css')):
app.add_stylesheet(cssf.split(os.path.sep, 1)[1])

# add custom javascript
jsdir = os.path.join(sdir, 'js')
for jsf in glob.glob(os.path.join(jsdir, '*.js')):
app.add_javascript(jsf.split(os.path.sep, 1)[1])
html_css_files = [
'css/custom.css',
]


# -- setup --------------------------------------------------------------------

def setup(app):
setup_static_content(app)
app.connect('builder-inited', run_apidoc)
Loading