Persist persistent_settings.dat on steam deck.

This commit is contained in:
Tom Alexander 2025-05-26 18:23:10 -04:00
parent 3a4344a112
commit 38a1168a32
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
2 changed files with 14 additions and 1 deletions

View File

@ -68,7 +68,6 @@ in
source = ./files/CurrentSettings.ini;
};
# TODO: Persist file .config/rpcs3/GuiConfigs/persistent_settings.dat # play times and recently played
me.persist.directories = [
".config/rpcs3/games" # Location of ROMs.
".config/rpcs3/dev_hdd0"
@ -79,6 +78,9 @@ in
".config/rpcs3/input_configs" # Controller config.
".config/rpcs3/Icons" # Game icons.
];
me.persist.files = [
".config/rpcs3/GuiConfigs/persistent_settings.dat" # play times and recently played
];
me.state.directories = [ ".cache/rpcs3" ];
nixpkgs.overlays = [

View File

@ -16,6 +16,12 @@
example = [ ".local/share/dolphin-emu/Wii" ];
description = "List of folders relative to the home directory to persist.";
};
persist.files = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
example = [ ".local/share/foo.sqlite3" ];
description = "List of files relative to the home directory to persist.";
};
state.directories = lib.mkOption {
type = lib.types.listOf lib.types.str;
default = [ ];
@ -50,6 +56,11 @@
);
};
})
(lib.mkIf (config.me.persist.files != [ ]) {
home.persistence."/home/deck/.persist" = {
files = config.me.persist.files;
};
})
(lib.mkIf (config.me.state.directories != [ ]) {
home.persistence."/home/deck/.state" = {
directories = (