clan: use .local/share as default for XDG_DATA_HOME

This commit is contained in:
Jörg Thalheim 2023-11-09 16:37:58 +01:00
parent 0206210b7e
commit af0714132d
2 changed files with 2 additions and 2 deletions

View File

@ -48,7 +48,7 @@ def user_data_dir() -> Path:
elif sys.platform == "darwin":
return Path(os.path.expanduser("~/Library/Application Support/"))
else:
return Path(os.getenv("XDG_DATA_HOME", os.path.expanduser("~/.local/state")))
return Path(os.getenv("XDG_DATA_HOME", os.path.expanduser("~/.local/share")))
def clan_data_dir() -> Path:

View File

@ -55,7 +55,7 @@ def create_flake(
template = Path(__file__).parent / flake_name
# copy the template to a new temporary location
flake = temporary_home / ".local/state/clan/flake" / flake_name
flake = temporary_home / ".local/share/clan/flake" / flake_name
shutil.copytree(template, flake)
# lookup the requested machines in ./test_machines and include them