diff --git a/src/config/__init__.py b/src/config/__init__.py index f856df3..04d1d94 100644 --- a/src/config/__init__.py +++ b/src/config/__init__.py @@ -1,4 +1,5 @@ from ._cache import get_cache_dir from ._env import load_envs +from ._path import get_project_root -__all__ = ["load_envs", "get_cache_dir"] +__all__ = ["load_envs", "get_cache_dir", "get_project_root"] diff --git a/src/config/_path.py b/src/config/_path.py new file mode 100644 index 0000000..0bf09e6 --- /dev/null +++ b/src/config/_path.py @@ -0,0 +1,5 @@ +from pathlib import Path + + +def get_project_root() -> Path: + return Path(__file__).parents[2].resolve()