| 1 | # .readthedocs.yml |
| 2 | # Read the Docs configuration file |
| 3 | # See https://docs.readthedocs.io/en/stable/config-file/v2.html for details |
| 4 | |
| 5 | # Required |
| 6 | version: 2 |
| 7 | |
| 8 | # Build documentation in the docs/ directory with Sphinx |
| 9 | sphinx: |
| 10 | configuration: docs/conf.py |
| 11 | |
| 12 | # Optionally build your docs in additional formats such as PDF and ePub |
| 13 | formats: all |
| 14 | |
| 15 | build: |
| 16 | os: ubuntu-24.04 |
| 17 | tools: |
| 18 | python: "3.13" |
| 19 | commands: |
| 20 | - git fetch --tags |
| 21 | - pip install build |
| 22 | - python -m build |
| 23 | # Cancel building pull requests when there aren't changes in the docs directory or YAML file. |
| 24 | # You can add any other files or directories that you'd like here as well, |
| 25 | # like your docs requirements file, or other files that will change your docs build. |
| 26 | # |
| 27 | # If there are no changes (git diff exits with 0) we force the command to return with 183. |
| 28 | # This is a special exit code on Read the Docs that will cancel the build immediately. |
| 29 | - | |
| 30 | if [ "$READTHEDOCS_VERSION_TYPE" = "external" ] && git diff --quiet origin/main -- . docs/ recurring_ical_events/ *.rst .readthedocs.yaml docs/requirements.txt; |
| 31 | then |
| 32 | exit 183; |
| 33 | fi |
| 34 | - cd docs && make rtd-pr-preview |