Skip to content

Commit

Permalink
Merge pull request #18 from wpreimes/ts2img
Browse files Browse the repository at this point in the history
New Ts2img implementation
  • Loading branch information
wpreimes authored Aug 8, 2023
2 parents 881a903 + 8f576d1 commit c6112e2
Show file tree
Hide file tree
Showing 20 changed files with 6,813 additions and 261 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
- name: Install package and test
shell: bash -l {0}
run: |
pip install .
pip install -e .[testing]
pytest
- name: Upload Coverage
shell: bash -l {0}
Expand Down
3 changes: 2 additions & 1 deletion .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ sphinx:
configuration: docs/conf.py

conda:
environment: environment.yml
environment: docs/env.yml

1 change: 0 additions & 1 deletion docs/_static/.gitignore

This file was deleted.

36 changes: 35 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,39 @@
import sys
import shutil


import subprocess

# Create kernel for notebooks
on_rtd = "READTHEDOCS" in os.environ and os.environ["READTHEDOCS"]
if on_rtd:
rtd_project = os.environ["READTHEDOCS_PROJECT"]
rtd_version = os.environ["READTHEDOCS_VERSION"]
interpreter = (
f"/home/docs/checkouts/readthedocs.org/user_builds/{rtd_project}/"
f"conda/{rtd_version}/bin/python"
)
else:
interpreter = "python"

print("Installing kernel")
subprocess.run(
[
interpreter,
"-m",
"ipykernel",
"install",
"--user",
"--name",
"conda-env-repurpose-py",
"--display-name",
"Python [conda env:repurpose]"
],
check=True,
capture_output=True,
)
print("Done")

# -- Path setup --------------------------------------------------------------

__location__ = os.path.dirname(__file__)
Expand Down Expand Up @@ -72,6 +105,7 @@
"sphinx.ext.ifconfig",
"sphinx.ext.mathjax",
"sphinx.ext.napoleon",
"nbsphinx",
]

# Add any paths that contain templates here, relative to this directory.
Expand Down Expand Up @@ -153,7 +187,7 @@

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = "alabaster"
html_theme = "sphinx_rtd_theme"

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
Expand Down
16 changes: 16 additions & 0 deletions docs/env.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# To keep the RTD build as small as possible, we define a separate .yml here
name: docs
channels:
- conda-forge
- defaults
dependencies:
- python=3.10
- ipykernel
- nbsphinx
- mock
- pillow
- sphinx<7
- sphinx_rtd_theme
- pip:
- recommonmark
- readthedocs-sphinx-ext
Loading

0 comments on commit c6112e2

Please sign in to comment.