Implement canon conformance and maintenance optimizations
Assistant: codex Assistant-Model: gpt-6-astra Assistant-Session: 01a06e82-3e08-7042-a79d-438ac6eed8db
This commit is contained in:
parent
a2e7f22d8d
commit
b081d39da1
64 changed files with 4491 additions and 373 deletions
15
src/info_tech_canon/paths.py
Normal file
15
src/info_tech_canon/paths.py
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
"""Corpus location is independent of the installed Python package."""
|
||||
|
||||
import os
|
||||
from pathlib import Path
|
||||
|
||||
|
||||
def infospace_root(root: Path | str | None = None) -> Path:
|
||||
if root:
|
||||
return Path(root).resolve()
|
||||
if os.environ.get("INFO_TECH_CANON_ROOT"):
|
||||
return Path(os.environ["INFO_TECH_CANON_ROOT"]).resolve()
|
||||
local = Path.cwd() / "infospace"
|
||||
if local.is_dir():
|
||||
return local.resolve()
|
||||
return Path(__file__).resolve().parents[2] / "infospace"
|
||||
Loading…
Add table
Add a link
Reference in a new issue