diff --git a/.readthedocs.yml b/.readthedocs.yml new file mode 100644 index 00000000..dbdc904b --- /dev/null +++ b/.readthedocs.yml @@ -0,0 +1,18 @@ +version: 2 +build: + image: latest +formats: + - htmlzip + - epub + - pdf +python: + version: 3.7 + install: + - method: pip + path: . + extra_requirements: + - docs +sphinx: + builder: html + configuration: docs/conf.py + fail_on_warning: true diff --git a/docs/conf.py b/docs/conf.py index c45874f3..2cbaf7b4 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,5 +1,3 @@ -import sphinx_rtd_theme - from platformdirs.version import __version__ author = "The platformdirs team" @@ -12,11 +10,4 @@ "sphinx.ext.autosectionlabel", "sphinx.ext.viewcode", ] -html_theme = "sphinx_rtd_theme" -html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] -html_theme_options = { - "canonical_url": "https://platformdirs.readthedocs.io/", - "display_version": True, - "prev_next_buttons_location": "bottom", - "sticky_navigation": True, -} +html_theme = "furo" diff --git a/setup.cfg b/setup.cfg index 23b12d7d..ee80a4a6 100644 --- a/setup.cfg +++ b/setup.cfg @@ -42,8 +42,8 @@ where = src [options.extras_require] docs = Sphinx>=4.1.1,<5.0.0 + furo>=2021.7.5b38 proselint>=0.10.2 - sphinx-rtd-theme>=0.4.3 test = appdirs@https://github.com/ActiveState/appdirs/archive/8eacfa312d77aba28d483fbfb6f6fc54099622be.zip pytest>=6 diff --git a/tox.ini b/tox.ini index ff8211d9..ba626526 100644 --- a/tox.ini +++ b/tox.ini @@ -69,7 +69,7 @@ commands = extras = docs commands = - python -c 'import glob; import subprocess; subprocess.call(["proselint"] + glob.glob("docs/*.rst") + glob.glob("docs/**/*.rst"))' + python -c 'import glob; import subprocess; subprocess.call(["proselint"] + glob.glob("docs/*.rst"))' sphinx-build -d "{envtmpdir}/doctree" docs "{toxworkdir}/docs_out" --color -b html {posargs} python -c 'import pathlib; print("documentation available under \{0\}".format((pathlib.Path(r"{toxworkdir}") / "docs_out" / "index.html").as_uri()))'