refactor: persist

This commit is contained in:
2025-06-29 15:13:29 +08:00
parent be5fd3b9ff
commit 13b69ccc95
11 changed files with 39 additions and 26 deletions

View File

@@ -22,10 +22,17 @@
nixosDirs = [ nixosDirs = [
"/root" "/root"
"/var" "/var"
"/etc/ssh"
]; ];
nixosFiles = [ nixosFiles = [
"/etc/machine-id" "/etc/machine-id"
]; ];
homeDirs = [
{
directory = ".ssh";
mode = "0700";
}
];
}; };
}; };
} }

View File

@@ -12,20 +12,11 @@
"workspace" "workspace"
"Virt" "Virt"
{
directory = ".ssh";
mode = "0700";
}
".local/state" ".local/state"
".local/share"
".local/share/nvim"
".cache" ".cache"
".ollama" ".ollama"
]; ];
nixosDirs = [
"/etc/ssh"
];
}; };
}; };
} }

View File

@@ -154,8 +154,6 @@
".android" ".android"
"Android" "Android"
".ssh"
"bin" "bin"
"workspace" "workspace"
"Virt" "Virt"
@@ -163,13 +161,9 @@
".cache" ".cache"
".local/state" ".local/state"
".local/share/Anki2" ".local/share/Anki2"
".local/share/nvim"
".local/share/shotwell" ".local/share/shotwell"
".local/share/Steam"
".local/share/SteamOS"
".local/share/cheat.sh" ".local/share/cheat.sh"
".local/share/Kingsoft" ".local/share/Kingsoft"
".local/share/oss.krtirtho.spotube"
".local/share/AyuGramDesktop" ".local/share/AyuGramDesktop"
".local/share/TelegramDesktop" ".local/share/TelegramDesktop"
@@ -182,21 +176,10 @@
".config/dconf" ".config/dconf"
".config/gh" ".config/gh"
".config/pulse" ".config/pulse"
".config/go-musicfox/db"
".config/pip" ".config/pip"
".config/obs-studio"
".config/libreoffice" ".config/libreoffice"
".config/Moonlight Game Streaming Project"
".config/sunshine" ".config/sunshine"
]; ];
nixosDirs = [
"/etc/ssh"
];
homeFiles = [
".config/mpd/mpd.db" # requires bindfs
".config/go-musicfox/cookie"
".hmcl.json"
];
}; };
}; };
} }

View File

@@ -23,6 +23,13 @@ lib.my.makeSwitch {
}; };
cli.media.mpd.enable = true; cli.media.mpd.enable = true;
persist.homeDirs = [
".config/go-musicfox/db"
];
persist.homeFiles = [
".config/go-musicfox/cookie"
];
}; };
}; };
} }

View File

@@ -21,5 +21,8 @@ lib.my.makeSwitch {
services.mpris-proxy.enable = true; services.mpris-proxy.enable = true;
xdg.configFile."mpd/mpd.conf".source = ./mpd.conf; xdg.configFile."mpd/mpd.conf".source = ./mpd.conf;
}; };
my.persist.homeFiles = [
".config/mpd/mpd.db"
];
}; };
} }

View File

@@ -54,5 +54,8 @@ lib.my.makeHomeProgramConfig {
]; ];
}; };
}; };
my.persist.homeDirs = [
".local/share/nvim"
];
}; };
} }

View File

@@ -23,5 +23,8 @@ lib.my.makeSwitch {
".minecraft" ".minecraft"
".local/share/hmcl" ".local/share/hmcl"
]; ];
my.persist.homeFiles = [
".hmcl.json"
];
}; };
} }

View File

@@ -20,5 +20,8 @@ lib.my.makeSwitch {
gamescope gamescope
]; ];
}; };
my.persist.homeDirs = [
".local/share/Steam"
];
}; };
} }

View File

@@ -13,4 +13,9 @@ lib.my.makeHomePackageConfig {
"media" "media"
"spotube" "spotube"
]; ];
extraConfig = {
my.persist.homeDirs = [
".local/share/oss.krtirtho.spotube"
];
};
} }

View File

@@ -21,5 +21,8 @@ lib.my.makeSwitch {
]; ];
}) })
]; ];
my.persist.homeDirs = [
".config/obs-studio"
];
}; };
} }

View File

@@ -32,6 +32,11 @@ in
"virt" "virt"
"moonlight" "moonlight"
]; ];
extraConfig = {
my.persist.homeDirs = [
".config/Moonlight Game Streaming Project"
];
};
}) })
]; ];