Files
incus-rpm/incus-0.2-doc-Remove-downloads-from-sphinx-build.patch
2024-04-27 09:01:55 -04:00

34 lines
1.4 KiB
Diff

commit 2900cdecd34ce65f047bf1740e17e8954472b1de
Author: Reto Gantenbein <reto.gantenbein@linuxmonk.ch>
Date: Mon Oct 9 23:22:25 2023 +0200
doc: Remove downloads from sphinx build
diff --git a/doc/conf.py b/doc/conf.py
index 6196d68b0..86b8988e2 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -5,22 +5,8 @@ import stat
import subprocess
import tempfile
import yaml
-from git import Repo
import filecmp
-# Download and link swagger-ui files
-if not os.path.isdir('.sphinx/deps/swagger-ui'):
- Repo.clone_from('https://github.com/swagger-api/swagger-ui', '.sphinx/deps/swagger-ui', depth=1)
-
-os.makedirs('.sphinx/_static/swagger-ui/', exist_ok=True)
-
-if not os.path.islink('.sphinx/_static/swagger-ui/swagger-ui-bundle.js'):
- os.symlink('../../deps/swagger-ui/dist/swagger-ui-bundle.js', '.sphinx/_static/swagger-ui/swagger-ui-bundle.js')
-if not os.path.islink('.sphinx/_static/swagger-ui/swagger-ui-standalone-preset.js'):
- os.symlink('../../deps/swagger-ui/dist/swagger-ui-standalone-preset.js', '.sphinx/_static/swagger-ui/swagger-ui-standalone-preset.js')
-if not os.path.islink('.sphinx/_static/swagger-ui/swagger-ui.css'):
- os.symlink('../../deps/swagger-ui/dist/swagger-ui.css', '.sphinx/_static/swagger-ui/swagger-ui.css')
-
### MAN PAGES ###
# Find the path to the incus binary
path = str(subprocess.check_output(['go', 'env', 'GOPATH'], encoding="utf-8").strip())