fix(docs): prevent a virtual environment from failing a build

sphinx-build is passed a blanket "." to build all docs. However, if a
virtual environment is placed within the docs directory, sphinx will try
to build it which will fail due to some weird files it has.

This excludes the most common virtual environment directories from the
build to prevent this.

Signed-off-by: Boyan Karatotev <boyan.karatotev@arm.com>
Change-Id: Ieeb14cfc5730d21c986611feb0ed379c58dfcae2
This commit is contained in:
Boyan Karatotev 2022-10-27 11:28:23 +01:00
parent fbcbd88eb1
commit 3fd1fe388e
2 changed files with 8 additions and 1 deletions

6
.gitignore vendored
View file

@ -43,3 +43,9 @@ tags
# Node.js
node_modules/
# common python virtual environment directories
.env/
env/
.venv/
venv/

View file

@ -41,7 +41,8 @@ language = None
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path .
exclude_patterns = []
# Don't try to build the venv in case it's placed with the sources
exclude_patterns = [".env", "env", ".venv", "venv"]
# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'