# .readthedocs.yml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Build documentation in the docs/ directory with Sphinx
sphinx:
  configuration: doc/api-docs/conf.py
  fail_on_warning: true

conda:
  environment: .readthedocs_environment.yml

build:
  os: ubuntu-22.04
  tools:
    python: "mambaforge-4.10"
  jobs:
    post_create_environment:
      - pip install --upgrade-strategy=only-if-needed -r requirements.txt
      - pip install --upgrade-strategy=only-if-needed -r requirements-dev.txt
      - pip install --upgrade-strategy=only-if-needed -r requirements-docs.txt
    post_install:
      - make install
