dirs: opportuniscally create directories
This commit is contained in:
parent
657cdd6e67
commit
c0be813a4c
@ -44,17 +44,13 @@ def user_config_dir() -> Path:
|
|||||||
|
|
||||||
def clan_config_dir() -> Path:
|
def clan_config_dir() -> Path:
|
||||||
path = user_config_dir() / "clan"
|
path = user_config_dir() / "clan"
|
||||||
if not path.exists():
|
path.mkdir(parents=True, exist_ok=True)
|
||||||
log.debug(f"Creating path with parents {path}")
|
|
||||||
path.mkdir(parents=True)
|
|
||||||
return path.resolve()
|
return path.resolve()
|
||||||
|
|
||||||
|
|
||||||
def clan_flakes_dir() -> Path:
|
def clan_flakes_dir() -> Path:
|
||||||
path = clan_config_dir() / "flakes"
|
path = clan_config_dir() / "flakes"
|
||||||
if not path.exists():
|
path.mkdir(parents=True, exist_ok=True)
|
||||||
log.debug(f"Creating path with parents {path}")
|
|
||||||
path.mkdir(parents=True)
|
|
||||||
return path.resolve()
|
return path.resolve()
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user