Skip to content

Commit

Permalink
Add back old conf.py with warning (#279)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cadair authored Nov 28, 2024
1 parent bae8169 commit f717793
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions src/sunpy_sphinx_theme/conf.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
"""
This config file is kept for backwards compatibility, almost all the config has
now been moved into the theme itself or can be imported from the main namespace
of the theme.
"""

from sphinx.util import logging

from sunpy_sphinx_theme import ON_RTD as on_rtd # noqa: N811
from sunpy_sphinx_theme import PNG_ICON as png_icon # noqa: N811
from sunpy_sphinx_theme import SVG_ICON as svg_icon # noqa: N811
from sunpy_sphinx_theme import get_html_theme_path

_log = logging.getLogger(__name__)

_log.warning(
"Using sunpy_sphinx_theme.conf is deprecated, please migrate to importing things you need directly from sunpy_sphinx_theme."
)

__all__ = [
"html_static_path",
"html_theme_path",
"html_theme",
"on_rtd",
"png_icon",
"svg_icon",
]

html_theme = "sunpy"
html_theme_options = {}

html_theme_path = [str(get_html_theme_path())]
html_static_path = [str(get_html_theme_path() / "static")]

0 comments on commit f717793

Please sign in to comment.