diff --git a/{{cookiecutter.project_name}}/docs/conf.py b/{{cookiecutter.project_name}}/docs/conf.py index 3c4aa472..dc3f7aea 100644 --- a/{{cookiecutter.project_name}}/docs/conf.py +++ b/{{cookiecutter.project_name}}/docs/conf.py @@ -22,13 +22,15 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ + "myst_parser", "sphinx.ext.autodoc", "sphinx.ext.mathjax", "sphinx.ext.napoleon", + "sphinx_copybutton", ] # Add any paths that contain templates here, relative to this directory. -templates_path = ["_templates"] +templates_path = [] # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. @@ -41,7 +43,19 @@ # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. # -html_theme = "sphinx_rtd_theme" +html_theme = "sphinx_book_theme" + +html_title = f"Hist {version}" + +html_baseurl = "https://{{ cookiecutter.project_name.replace("-", "_") }}.readthedocs.io/en/latest/" + +html_theme_options = { + "home_page_in_toc": True, + "repository_url": "{{ cookiecutter.url }}", + "use_repository_button": True, + "use_issues_button": True, + "use_edit_page_button": True, +} # Add any paths that contain custom static files (such as style sheets) here, # relative to this directory. They are copied after the builtin static files, diff --git a/{{cookiecutter.project_name}}/pyproject-flit.toml b/{{cookiecutter.project_name}}/pyproject-flit.toml index 5aa74309..a3f979fa 100644 --- a/{{cookiecutter.project_name}}/pyproject-flit.toml +++ b/{{cookiecutter.project_name}}/pyproject-flit.toml @@ -37,10 +37,10 @@ dev = [ "pytest >=4.6", ] docs = [ - "recommonmark >=0.5.0", "Sphinx >=3.0.0", + "myst_parser>=0.13", + "sphinx-book-theme>=0.0.33", "sphinx_copybutton", - "sphinx_rtd_theme >=0.5.0", ] [build-system] diff --git a/{{cookiecutter.project_name}}/pyproject-poetry.toml b/{{cookiecutter.project_name}}/pyproject-poetry.toml index 617cc3a0..81659319 100644 --- a/{{cookiecutter.project_name}}/pyproject-poetry.toml +++ b/{{cookiecutter.project_name}}/pyproject-poetry.toml @@ -36,10 +36,10 @@ dev = [ "pytest >=4.6", ] docs = [ - "recommonmark >=0.5.0", "Sphinx >=3.0.0", + "myst_parser>=0.13", + "sphinx-book-theme>=0.0.33", "sphinx_copybutton", - "sphinx_rtd_theme >=0.5.0", ] [build-system] diff --git a/{{cookiecutter.project_name}}/setup.cfg b/{{cookiecutter.project_name}}/setup.cfg index 7b32be75..1196d7de 100644 --- a/{{cookiecutter.project_name}}/setup.cfg +++ b/{{cookiecutter.project_name}}/setup.cfg @@ -50,9 +50,9 @@ dev = pytest>=4.6 docs = Sphinx>=3.0.0 - recommonmark>=0.5.0 + myst_parser>=0.13 + sphinx-book-theme>=0.0.33 sphinx_copybutton - sphinx_rtd_theme>=0.5.0 test = pytest>=4.6