about summary refs log tree commit diff stats
path: root/modules/by-name/im
diff options
context:
space:
mode:
Diffstat (limited to 'modules/by-name/im')
-rw-r--r--modules/by-name/im/impermanence/module.nix21
1 files changed, 17 insertions, 4 deletions
diff --git a/modules/by-name/im/impermanence/module.nix b/modules/by-name/im/impermanence/module.nix
index 4ce86b25..78ad570f 100644
--- a/modules/by-name/im/impermanence/module.nix
+++ b/modules/by-name/im/impermanence/module.nix
@@ -31,6 +31,21 @@ in {
       }));
       description = "The directories to persist";
     };
+
+    userDirectories = lib.mkOption {
+      type = lib.types.listOf (lib.types.either lib.types.str (lib.types.submodule {
+        options = {
+          directory = lib.mkOption {
+            type = lib.types.str;
+          };
+          mode = lib.mkOption {
+            type = lib.types.str;
+          };
+        };
+      }));
+      default = [];
+      description = "The directories to persist";
+    };
   };
 
   imports = [
@@ -53,15 +68,13 @@ in {
             ".local/state/wireplumber"
 
             ".config/Signal"
-            ".config/iamb/profiles"
 
             ".cache"
-            ".mozilla/firefox"
 
             "media"
             "repos"
-            "school"
-          ];
+            "documents"
+          ] ++ cfg.userDirectories;
         };
 
         files = [