Skip to content

Commit

Permalink
speed up doc build time
Browse files Browse the repository at this point in the history
  • Loading branch information
johntruckenbrodt committed Mar 13, 2023
1 parent a48aad3 commit 818da8f
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 14 deletions.
10 changes: 3 additions & 7 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
# release is automatically added to the latex document title and header
release = version

autodoc_mock_imports = ['osgeo', 'sqlite3']
autodoc_mock_imports = ['osgeo', 'sqlalchemy', 'sqlalchemy_utils', 'geoalchemy2',
'lxml', 'progressbar', 'spatialist']

# If your documentation needs a minimal Sphinx version, state it here.
needs_sphinx = '1.6'
Expand All @@ -43,16 +44,11 @@
# autodoc_default_flags = ['members']
autosummary_generate = []

# explicitly link to documentation of the spatialist version installed alongside pyroSAR,
# which is defined in setup.py and requirements.txt
version_spatialist = get_version('spatialist')

intersphinx_mapping = {'osgeo': ('https://gdal.org', None),
'python': ('https://docs.python.org/3', None),
'requests': ('https://requests.readthedocs.io/en/latest', None),
'scipy': ('https://docs.scipy.org/doc/scipy', None),
'spatialist': ('https://spatialist.readthedocs.io/en/v{}'
.format(version_spatialist), None),
'spatialist': ('https://spatialist.readthedocs.io/en/latest', None),
'sqlalchemy': ('https://docs.sqlalchemy.org/en/latest', None),
'sqlalchemy-utils': ('https://sqlalchemy-utils.readthedocs.io/en/latest', None)
}
Expand Down
6 changes: 0 additions & 6 deletions environment-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,3 @@ dependencies:
- coveralls
- coverage
- pytest
- sphinx
- sphinxcontrib-bibtex>=2.2
- pip
- cairosvg
- pip:
- sphinxcontrib-svg2pdfconverter
13 changes: 13 additions & 0 deletions environment-doc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: ps_doc
channels:
- conda-forge
- defaults
dependencies:
- matplotlib
- numpy
- sphinx
- sphinxcontrib-bibtex>=2.2
- pip
- cairosvg
- pip:
- sphinxcontrib-svg2pdfconverter
2 changes: 1 addition & 1 deletion readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ build:
python: "mambaforge-4.10"

conda:
environment: environment-dev.yml
environment: environment-doc.yml

python:
install:
Expand Down

0 comments on commit 818da8f

Please sign in to comment.