Skip to content

Commit

Permalink
update and move doc deps into group instead of extras, update RTD con…
Browse files Browse the repository at this point in the history
…fig (#460)
  • Loading branch information
ITProKyle authored Apr 16, 2024
1 parent 2f6f1b0 commit a63a9dc
Show file tree
Hide file tree
Showing 4 changed files with 112 additions and 126 deletions.
30 changes: 14 additions & 16 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,23 @@
# .readthedocs.yml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

build:
os: ubuntu-20.04
os: ubuntu-22.04
tools:
python: '3.10'

# Optionally build your docs in additional formats such as PDF and ePub
formats: all

# Optionally set the version of Python and requirements required to build your docs
python:
install:
- method: pip
path: .
extra_requirements:
- docs
python: '3.12'
jobs:
post_create_environment:
# Install poetry
# https://python-poetry.org/docs/#installing-manually
- pip install poetry
- poetry self add "poetry-dynamic-versioning[plugin]"
post_install:
# Install dependencies with 'docs' dependency group
# https://python-poetry.org/docs/managing-dependencies/#dependency-groups
# VIRTUAL_ENV needs to be set manually for now.
# See https://github.com/readthedocs/readthedocs.org/pull/11152/
- VIRTUAL_ENV=$READTHEDOCS_VIRTUALENV_PATH poetry install --with docs

# Build documentation in the docs/ directory with Sphinx
sphinx:
Expand Down
4 changes: 1 addition & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,7 @@ setup-npm: ## install node dependencies with npm

setup-poetry: ## setup python virtual environment
@poetry check
@poetry install $(POETRY_OPTS) \
--extras docs \
--sync
@poetry install $(POETRY_OPTS) --sync

setup-pre-commit: ## install pre-commit git hooks
@poetry run pre-commit install
Expand Down
Loading

0 comments on commit a63a9dc

Please sign in to comment.