Skip to content

Commit

Permalink
doc: work around circular dependency
Browse files Browse the repository at this point in the history
Manually install gitpython, because it must be available to
generate the requirements.txt file, which is before the venv is
created.

Issue for this is here:
canonical/sphinx-docs-starter-pack#197

Signed-off-by: Ruth Fuchss <[email protected]>
  • Loading branch information
ru-fu committed Mar 12, 2024
1 parent 62afeb0 commit 83435d6
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ update-metadata: build
.PHONY: doc-setup
doc-setup: client
@echo "Setting up documentation build environment"
pip3 install gitpython
cd doc; LOCAL_SPHINX_BUILD=True python3 .sphinx/build_requirements.py
python3 -m venv doc/.sphinx/venv
. $(SPHINXENV) ; pip install --require-virtualenv --upgrade -r doc/.sphinx/requirements.txt --log doc/.sphinx/venv/pip_install.log
Expand Down
2 changes: 2 additions & 0 deletions doc/.readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ build:
python: "3.11"
jobs:
post_checkout:
- apt-get install python3-pip
- python3 -m pip install gitpython
- cd doc; python3 .sphinx/build_requirements.py
pre_build:
- go build -ldflags "-s -w" -o trimpath -o lxc.bin ./lxc
Expand Down

0 comments on commit 83435d6

Please sign in to comment.