-
Notifications
You must be signed in to change notification settings - Fork 0
/
.readthedocs.yaml
74 lines (62 loc) · 2.6 KB
/
.readthedocs.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
# Required
version: 2
# Set the OS, Python version and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.10"
# You can also specify other tool versions:
# nodejs: "19"
# rust: "1.64"
# golang: "1.19"
# ALL JOBS implied: https://docs.readthedocs.io/en/stable/builds.html
# Step Customizable jobs
# Checkout post_checkout
# System dependencies pre_system_dependencies, post_system_dependencies
# Create environment pre_create_environment, post_create_environment
# Install pre_install, post_install
# Build pre_build, post_build
jobs:
# post_system_dependencies:
# - python3 -m pip install --user poetry
# V2
# post_create_environment:
# # Install poetry
# # https://python-poetry.org/docs/#installing-manually
# - pip install poetry
# # V2
# 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 -E docs
# V1
pre_install:
- python --version
# generate compatible and pinned dependencies in pip format, for python3.10
- python -m pip install poetry
- python -m pip install setuptools==71.0.0
- python -m poetry export -o req-docs.txt -E docs
- python -m pip install --no-build-isolation -r req-docs.txt
# Ref Pages are kept up-to-date with scripts/gen-docs-refs.sh, so we do not pre_build
pre_build:
- python -m pip install setuptools==71.0.0
# - chmod +x ./scripts/gen-workflow-ref.py
# - ./scripts/gen-workflow-ref.py ./.github/workflows/docker.yml > ./docs/ref_docker.md
# - ./scripts/gen-workflow-ref.py ./.github/workflows/pypi_env.yml > ./docs/ref_pypi_env.md
# - ./scripts/gen-workflow-ref.py ./.github/workflows/lint.yml > ./docs/ref_lint.md
# - ./scripts/gen-workflow-ref.py ./.github/workflows/python_imports.yml > ./docs/ref_pydeps.md
# Build documentation in the "docs/" directory with mkdocs
mkdocs:
configuration: mkdocs.yml
# V1
# Optional but recommended, declare the Python requirements required
# to build your documentation
# See https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: req-docs.txt