diff --git a/src/utils/utils.py b/src/utils/utils.py index 56c2d43..ccf9a15 100644 --- a/src/utils/utils.py +++ b/src/utils/utils.py @@ -52,7 +52,10 @@ def setup_cursor_hover( ) -# Base path to your SVG assets (resolve from repository root) +# Base path to config directory +BASE_CONFIG_PATH = (Path(__file__).resolve().parent.parent.parent / "config").resolve() + +# Base path to SVG assets BASE_SVG_PATH = (Path(__file__).resolve().parent.parent / "assets" / "icons").resolve() @@ -111,6 +114,11 @@ def svg_file(relative_path: str, **kwargs) -> Svg: return svg +def toml_file(relative_path: str) -> str: + """Return absolute path to a TOML file in config/.""" + return str(BASE_CONFIG_PATH / relative_path) + + def generate_colors_from_wallpaper(image_path: str) -> bool: cmd = f'matugen image "{image_path}" --source-color-index 0' return bool(exec_shell_command_async(cmd))