Skip to content

Commit

Permalink
Use read the docs v2 config
Browse files Browse the repository at this point in the history
  • Loading branch information
ianthomas23 committed Feb 1, 2023
1 parent 7bf10b8 commit 5dd592c
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 15 deletions.
18 changes: 18 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: 2

build:
os: ubuntu-22.04
tools:
python: miniconda3-4.7

conda:
environment: docs/environment.yml

python:
install:
- method: pip
path: .

sphinx:
configuration: docs/source/conf.py
fail_on_warning: true
9 changes: 9 additions & 0 deletions docs/environment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: s3fs
channels:
- defaults
dependencies:
- python= 3.9
- botocore
- docutils<0.18
- numpydoc
- sphinx_rtd_theme
5 changes: 0 additions & 5 deletions docs/requirements.txt

This file was deleted.

13 changes: 3 additions & 10 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
# All configuration values have a default; values that are commented out
# serve to show the default.

import sys
import os

# If extensions (or modules to document with autodoc) are in another directory,
Expand Down Expand Up @@ -113,20 +112,13 @@
todo_include_todos = False

extlinks = {
"pr": ("https://github.com/fsspec/s3fs/pull/%s", "PR #"),
"pr": ("https://github.com/fsspec/s3fs/pull/%s", "PR #%s"),
}


# -- Options for HTML output ----------------------------------------------

# Taken from docs.readthedocs.io:
# on_rtd is whether we are on readthedocs.io
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'

if not on_rtd: # only import and set the theme if we're building docs locally
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
html_theme = 'sphinx_rtd_theme'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
Expand Down Expand Up @@ -278,6 +270,7 @@
#man_show_urls = False



# -- Options for Texinfo output -------------------------------------------

# Grouping the document tree into Texinfo files. List of tuples
Expand Down

0 comments on commit 5dd592c

Please sign in to comment.