mirror of
https://github.com/craigerl/aprsd.git
synced 2026-01-08 17:39:17 -05:00
The documenation now has a new theme and updated apidocs. Also the main index is built from the README.md contents.
23 lines
526 B
Python
23 lines
526 B
Python
#!/usr/bin/env python3
|
|
|
|
"""Removes temporary Sphinx build artifacts to ensure a clean build.
|
|
|
|
This is needed if the Python source being documented changes significantly. Old sphinx-apidoc
|
|
RST files can be left behind.
|
|
"""
|
|
|
|
import shutil
|
|
from pathlib import Path
|
|
|
|
|
|
def main() -> None:
|
|
docs_dir = Path(__file__).resolve().parent
|
|
for folder in ('build', 'source/apidoc'):
|
|
delete_dir = docs_dir / folder
|
|
if delete_dir.exists():
|
|
shutil.rmtree(delete_dir)
|
|
|
|
|
|
if __name__ == '__main__':
|
|
main()
|