mirror of
https://github.com/RYDE-WORK/ballistica.git
synced 2026-02-07 08:03:30 +08:00
modified: Makefile
modified: tools/batools/docs.py
This commit is contained in:
parent
2467673334
commit
3527214713
3
Makefile
3
Makefile
@ -188,6 +188,9 @@ docs-sphinx:
|
|||||||
$(MAKE) dummymodules
|
$(MAKE) dummymodules
|
||||||
@$(PCOMMAND) gen_docs_sphinx
|
@$(PCOMMAND) gen_docs_sphinx
|
||||||
|
|
||||||
|
docs-sphinx-clean:
|
||||||
|
rm -rf .cache/sphinx
|
||||||
|
|
||||||
pcommandbatch_speed_test: prereqs
|
pcommandbatch_speed_test: prereqs
|
||||||
@$(PCOMMAND) pcommandbatch_speed_test $(PCOMMANDBATCH)
|
@$(PCOMMAND) pcommandbatch_speed_test $(PCOMMANDBATCH)
|
||||||
|
|
||||||
|
|||||||
@ -234,7 +234,7 @@ def _run_sphinx() -> None:
|
|||||||
assert template_dir.is_dir()
|
assert template_dir.is_dir()
|
||||||
build_dir = 'build/sphinx/'
|
build_dir = 'build/sphinx/'
|
||||||
os.makedirs(build_dir, exist_ok=True)
|
os.makedirs(build_dir, exist_ok=True)
|
||||||
sphinx_apidoc_out = build_dir + 'apidoc/'
|
sphinx_apidoc_out = '.cache/sphinx/' # might want to use .cache dir
|
||||||
os.makedirs(sphinx_apidoc_out, exist_ok=True)
|
os.makedirs(sphinx_apidoc_out, exist_ok=True)
|
||||||
|
|
||||||
|
|
||||||
@ -257,7 +257,7 @@ def _run_sphinx() -> None:
|
|||||||
|
|
||||||
|
|
||||||
subprocess.run( ['make', 'html'], check = True, cwd= sphinx_apidoc_out)
|
subprocess.run( ['make', 'html'], check = True, cwd= sphinx_apidoc_out)
|
||||||
shutil.copytree(sphinx_apidoc_out + '_build/html/', build_dir+'html/', dirs_exist_ok=True)
|
shutil.copytree(sphinx_apidoc_out + '_build/html/', build_dir, dirs_exist_ok=True)
|
||||||
# shutil.rmtree(temp_modules_dir)
|
# shutil.rmtree(temp_modules_dir)
|
||||||
duration = time.monotonic() - starttime
|
duration = time.monotonic() - starttime
|
||||||
print(f'Generated sphinx documentation in {duration:.1f}s.')
|
print(f'Generated sphinx documentation in {duration:.1f}s.')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user