(config)
| 33 | |
| 34 | |
| 35 | def load_nedoc_config(config) -> nedoc.config.Config: |
| 36 | docs_dir = Path(config["docs_dir"]) |
| 37 | root_dir = docs_dir.parent |
| 38 | conf_file = root_dir / "nedoc.conf" |
| 39 | if not conf_file.exists(): |
| 40 | raise Exception(f"nedoc configuration file {conf_file} does not exist. Run `nedoc init`.") |
| 41 | return nedoc.config.parse_config(str(conf_file)) |
| 42 | |
| 43 | |
| 44 | def build_nedoc(config: nedoc.config.Config, target_dir: Path): |