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

Automatic list with overviews of inlcuded area definitions for the documentation #2167

Merged
merged 21 commits into from
Jun 13, 2024
Merged
Show file tree
Hide file tree
Changes from 9 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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -75,3 +75,4 @@ doc/source/_build/*
satpy/version.py
doc/source/api/*.rst
doc/source/reader_table.rst
doc/source/area_def_list.rst
7 changes: 7 additions & 0 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,11 @@
sys.path.append(os.path.abspath('../../'))
sys.path.append(os.path.abspath(os.path.dirname(__file__)))

from pyresample.area_config import generate_area_def_rst_list # noqa: E402
from reader_table import generate_reader_table # noqa: E402

from satpy.resample import get_area_file # noqa: E402

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
# built documents.
Expand Down Expand Up @@ -80,6 +83,10 @@ def __getattr__(cls, name):
with open("reader_table.rst", mode="w") as f:
f.write(generate_reader_table())

area_file = get_area_file()[0]
with open("area_def_list.rst", mode="w") as f:
f.write(generate_area_def_rst_list(area_file))

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

# Add any Sphinx extension module names here, as strings. They can be extensions
Expand Down
7 changes: 6 additions & 1 deletion satpy/resample.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,12 @@

For examples of area definitions, see the file ``etc/areas.yaml`` that is
included with Satpy and where all the area definitions shipped with Satpy are
defined.
defined. The section below gives an overview of these area definitions.

Area definitions included in Satpy
----------------------------------

.. include:: area_def_list.rst

"""
import hashlib
Expand Down