Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorBastien Montagne <b.mont29@gmail.com>2020-02-10 14:37:15 +0300
committerBastien Montagne <b.mont29@gmail.com>2020-02-10 14:38:03 +0300
commit379ee3e52779050c63f531454c9c60e310601e77 (patch)
tree36b4b0e06dba32ec434202c460ef0f79b46e7b02 /doc
parent14d1dc5df565bdd3970579b31da9b2a26c306448 (diff)
PY API doc generation: Add option for multi-tasking sphinx.
Diffstat (limited to 'doc')
-rwxr-xr-xdoc/python_api/sphinx_doc_update.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/doc/python_api/sphinx_doc_update.py b/doc/python_api/sphinx_doc_update.py
index 78bfd3c85b8..d3f42b1d26f 100755
--- a/doc/python_api/sphinx_doc_update.py
+++ b/doc/python_api/sphinx_doc_update.py
@@ -27,7 +27,7 @@ You'll need to specify your user login and password, obviously.
Example usage:
- ./sphinx_doc_update.py --mirror ../../../docs/remote_api_backup/ --source ../.. --blender ../../../build_cmake/bin/blender --user foobar --password barfoo
+ ./sphinx_doc_update.py --jobs 16 --mirror ../../../docs/remote_api_backup/ --source ../.. --blender ../../../build_cmake/bin/blender --user foobar --password barfoo
"""
@@ -82,6 +82,10 @@ def argparse_create():
"--password", dest="password",
metavar='PASSWORD', type=str, required=True,
help=("Password to login on rsync server"))
+ parser.add_argument(
+ "--jobs", dest="jobs_nr",
+ metavar='NR', type=int, required=False, default=1,
+ help="Number of sphinx building jobs to launch in parallel")
return parser
@@ -141,7 +145,7 @@ def main():
# IV) Build doc.
curr_dir = os.getcwd()
os.chdir(tmp_dir)
- sphinx_cmd = ("sphinx-build", "-b", "html", "sphinx-in", "sphinx-out")
+ sphinx_cmd = ("sphinx-build", "-j", str(args.jobs_nr), "-b", "html", "sphinx-in", "sphinx-out")
subprocess.run(sphinx_cmd)
shutil.rmtree(os.path.join("sphinx-out", ".doctrees"))
os.chdir(curr_dir)