Skip to content

Commit

Permalink
Update conf.py
Browse files Browse the repository at this point in the history
  • Loading branch information
kjkoeller committed Feb 16, 2024
1 parent 51b78b9 commit ab96657
Showing 1 changed file with 62 additions and 45 deletions.
107 changes: 62 additions & 45 deletions docs/conf.py
Original file line number Diff line number Diff line change
@@ -1,54 +1,71 @@
import importlib.metadata
# Configuration file for the Sphinx documentation builder.

project = "EclipsingBinaries"
copyright = "2023, Kyle Koeller"
author = "Kyle KOeller"
version = release = importlib.metadata.version("EclipsingBinaries")
import datetime
import os
import sys

extensions = [
"sphinx.ext.autodoc",
"sphinx.ext.intersphinx",
"sphinx.ext.mathjax",
"sphinx.ext.napoleon",
"sphinx_autodoc_typehints",
"sphinx_copybutton",
"sphinx_automodapi.automodapi",
"sphinx_automodapi.smart_resolver",
]
# Get configuration information from setup.cfg
try:
from ConfigParser import ConfigParser
except ImportError:
from configparser import ConfigParser
conf = ConfigParser()

source_suffix = [".rst", ".md"]
exclude_patterns = [
"_build",
"**.ipynb_checkpoints",
"Thumbs.db",
".DS_Store",
".env",
".venv",
]
conf.read([os.path.join(os.path.dirname(__file__), '..', 'setup.cfg')])
setup_cfg = dict(conf.items('metadata'))

# By default, highlight as Python 3.
highlight_language = 'python3'

# exclude_patterns.append('_templates')

# -- Project information

project = setup_cfg['name']
author = setup_cfg['author']
copyright = '{0}, {1}'.format(
datetime.datetime.now().year, setup_cfg['author'])

__import__(project)
package = sys.modules[project]

ver = package.__version__
version = '.'.join(ver.split('.'))[:5]
release = ver

html_title = '{0} v{1}'.format(project, release)

html_theme = "pydata_sphinx_theme"
# The master toctree document.
root_doc = 'index'

man_pages = [('index', project.lower(), project + u' Documentation',
[author], 1)]

# -- General configuration
extensions = [
'sphinx.ext.duration',
'sphinx.ext.doctest',
'sphinx.ext.autodoc',
'sphinx.ext.autosummary',
'sphinx.ext.intersphinx',
'sphinx_rtd_theme',
]

intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"pandas": ("https://pandas.pydata.org/pandas-docs/stable/", None),
"numpy": (
"https://numpy.org/doc/stable/",
(None, "http://data.astropy.org/intersphinx/numpy.inv"),
),
"scipy": (
"https://docs.scipy.org/doc/scipy/",
(None, "http://data.astropy.org/intersphinx/scipy.inv"),
),
"matplotlib": (
"https://matplotlib.org/stable/",
(None, "http://data.astropy.org/intersphinx/matplotlib.inv"),
),
"astropy": ("https://docs.astropy.org/en/stable/", None),
'python': ('https://docs.python.org/3/', None),
'sphinx': ('https://www.sphinx-doc.org/en/master/', None),
}
intersphinx_disabled_domains = ['std']

templates_path = ['_templates']

# -- Options for HTML output
# html_theme = "sphinx_rtd_theme"

# -- Options for EPUB output
# epub_show_urls = 'footnote'
# github_issues_url = 'https://github.com/astropy/ccdproc/issues/'
# nitpicky = True


nitpick_ignore = [
("py:class", "_io.StringIO"),
("py:class", "_io.BytesIO"),
]

always_document_param_types = True

0 comments on commit ab96657

Please sign in to comment.