зеркало из https://github.com/microsoft/lisa.git
Update sphinx config
This commit is contained in:
Родитель
6617cec62a
Коммит
2add730312
|
@ -10,11 +10,11 @@ BUILDDIR = _build
|
|||
|
||||
# Put it first so that "make" without argument is like "make help".
|
||||
help:
|
||||
@poetry run $(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
||||
.PHONY: help Makefile
|
||||
|
||||
# Catch-all target: route all unknown targets to Sphinx using the new
|
||||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
||||
%: Makefile
|
||||
@poetry run $(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
||||
|
|
39
docs/conf.py
39
docs/conf.py
|
@ -15,52 +15,17 @@ import sys
|
|||
from pathlib import Path
|
||||
from typing import List
|
||||
|
||||
import toml
|
||||
|
||||
root_dir = Path(__file__).parent.parent
|
||||
pyproj = root_dir / "pyproject.toml"
|
||||
requirement = root_dir / "docs" / "requirements.txt"
|
||||
|
||||
# to import lisa package
|
||||
root_dir = Path(__file__).parent.parent
|
||||
sys.path.insert(0, str(root_dir))
|
||||
sys.path.insert(0, str(root_dir / "docs"))
|
||||
|
||||
from tools import update_file, update_summary # type: ignore # noqa: E402
|
||||
|
||||
data = toml.load(pyproj)
|
||||
dependencies = data["tool"]["poetry"]["dependencies"]
|
||||
sphinx_dependencies = data["tool"]["poetry"]["dev-dependencies"]
|
||||
|
||||
with open(requirement, "w") as req:
|
||||
for module, value in dependencies.items():
|
||||
if isinstance(value, dict):
|
||||
# Remove platform specific dependencies.
|
||||
if "platform" in value:
|
||||
continue
|
||||
version = value["version"]
|
||||
else:
|
||||
version = str(value)
|
||||
assert isinstance(module, str)
|
||||
if module in ["python"]:
|
||||
continue
|
||||
if version.startswith("^"):
|
||||
version = version[1:]
|
||||
req.write(module)
|
||||
req.write(">=")
|
||||
req.write(version)
|
||||
req.write("\n")
|
||||
|
||||
for module, version in sphinx_dependencies.items():
|
||||
if str(module)[:6].lower() == "sphinx":
|
||||
req.write(str(module))
|
||||
req.write(">=")
|
||||
req.write(str(version)[1:])
|
||||
req.write("\n")
|
||||
|
||||
# -- Project information -----------------------------------------------------
|
||||
|
||||
project = "Linux Integration Services Automation (LISA)"
|
||||
copyright = "2021, Microsoft"
|
||||
copyright = "Microsoft Corporation"
|
||||
author = "Microsoft"
|
||||
|
||||
release = ""
|
||||
|
|
|
@ -1,35 +0,0 @@
|
|||
PyYAML>=5.4.1
|
||||
assertpy>=1.1
|
||||
azure-identity>=1.9.0
|
||||
azure-storage-blob>=12.11.0
|
||||
azure-mgmt-compute>=26.1.0
|
||||
azure-mgmt-marketplaceordering>=1.1.0
|
||||
azure-mgmt-network>=19.3.0
|
||||
azure-mgmt-resource>=21.0.0
|
||||
azure-mgmt-serialconsole>=1.0.0
|
||||
azure-mgmt-storage>=20.0.0
|
||||
azure-storage-file-share>=12.4.0
|
||||
dataclasses-json>=0.5.2
|
||||
func-timeout>=4.3.5
|
||||
paramiko>=2.10.1
|
||||
pluggy>=0.13.1
|
||||
pytest-html>=3.1.1
|
||||
python-dateutil>=2.8.1
|
||||
retry>=0.9.2
|
||||
spurplus>=2.3.4
|
||||
semver>=2.13.0
|
||||
types-toml>=0.1.5
|
||||
pycdlib>=1.12.0
|
||||
randmac>=0.1
|
||||
toml>=0.10.2
|
||||
Pillow>=9.0.0
|
||||
websockets>=10.3
|
||||
boto3>=1.21.37
|
||||
boto3-stubs>=1.21.37
|
||||
Sphinx>=4.1.0
|
||||
sphinx-argparse>=0.2.5
|
||||
sphinx-rtd-theme>=0.5.2
|
||||
sphinxemoji>=0.1.8
|
||||
sphinx-copybutton>=0.4.0
|
||||
rstcheck>=3.3.1
|
||||
types-Pillow>=8.3.3
|
|
@ -8,4 +8,9 @@ sphinx:
|
|||
python:
|
||||
version: 3.8
|
||||
install:
|
||||
- requirements: docs/requirements.txt
|
||||
- method: pip
|
||||
path: .
|
||||
extra_requirements:
|
||||
- docs
|
||||
- aws
|
||||
- azure
|
||||
|
|
Загрузка…
Ссылка в новой задаче