Skip to content

Commit

Permalink
Use UV in readthedocs build (#1942)
Browse files Browse the repository at this point in the history
  • Loading branch information
davfsa authored Jun 20, 2024
1 parent c7d92a5 commit 8158832
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 11 deletions.
18 changes: 8 additions & 10 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,12 @@ version: 2
build:
os: ubuntu-22.04
tools:
# NOTE: This should be kept up to date with .ci.yml
# NOTE: This should be kept up to date with ci.yml
python: "3.11"

mkdocs:
configuration: mkdocs.yml

python:
install:
- requirements: dev-requirements/mkdocs.txt
- method: pip
path: .
commands:
- asdf plugin add uv
- asdf install uv latest
- asdf global uv latest
- uv venv
- uv pip install -r dev-requirements.txt
- .venv/bin/nox -s mkdocs
7 changes: 6 additions & 1 deletion pipelines/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,12 @@
FLAKE8_REPORT = _os.path.join(ARTIFACT_DIRECTORY, "flake8")
PYPROJECT_TOML = "pyproject.toml"
COVERAGE_HTML_PATH = _os.path.join(ARTIFACT_DIRECTORY, "coverage", "html")
DOCUMENTATION_OUTPUT_PATH = _os.path.join(ARTIFACT_DIRECTORY, "docs")

if "READTHEDOCS_OUTPUT" in _os.environ:
DOCUMENTATION_OUTPUT_PATH = _os.environ["READTHEDOCS_OUTPUT"] + "/html"
else:
DOCUMENTATION_OUTPUT_PATH = _os.path.join(ARTIFACT_DIRECTORY, "docs")


# Reformatting paths
REFORMATTING_FILE_EXTS = (
Expand Down

0 comments on commit 8158832

Please sign in to comment.