MCPcopy Index your code
hub / github.com/vastsa/FileCodeBox / resolve_theme_root

Function resolve_theme_root

main.py:806–815  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

804
805
806def resolve_theme_root():
807 themes_root = (BASE_DIR / "themes").resolve()
808 theme_root = (BASE_DIR / str(settings.themesSelect)).resolve()
809 try:
810 theme_root.relative_to(themes_root)
811 except ValueError:
812 theme_root = (BASE_DIR / DEFAULT_CONFIG["themesSelect"]).resolve()
813 if not theme_root.exists():
814 theme_root = (BASE_DIR / DEFAULT_CONFIG["themesSelect"]).resolve()
815 return theme_root
816
817
818def resolve_theme_file(*parts: str):

Callers 1

resolve_theme_fileFunction · 0.85

Calls 1

existsMethod · 0.80

Tested by

no test coverage detected