add udiskie for automount

This commit is contained in:
2025-11-12 21:10:22 -06:00
parent cfb55f980d
commit 7d97acfdfb
10 changed files with 119 additions and 4 deletions
+2
View File
@@ -14,6 +14,7 @@
./git
./xdg
./nh
./udiskie
];
dots = {
@@ -26,6 +27,7 @@
git.enable = lib.mkDefault true;
xdg.enable = lib.mkDefault true;
nh.enable = lib.mkDefault true;
udiskie.enable = lib.mkDefault true;
};
+1
View File
@@ -23,6 +23,7 @@ set ignorecase true
# shortcuts
map gb cd /holocron
map gz cd %{{ [ -d /holocron ] && printf /holocron || printf /media/holocron }}
map gn cd ~/.nix
map gc cd ~/.config
+34
View File
@@ -0,0 +1,34 @@
{
pkgs,
lib,
config,
...
}: let
program = "udiskie";
cfg = config.dots.${program};
home_dir = config.home.homeDirectory;
in {
options.dots.${program} = {
enable = lib.mkEnableOption "enables ${program}";
};
config = lib.mkIf cfg.enable {
programs.${program} = {
enable = true;
automount = true;
notify = true;
tray = "auto";
settings = {
rules = [
{
id_uuid = ["4E21-0000" "9EA2-A886"];
automount = true;
}
];
};
};
# add userspace tools
home.packages = with pkgs; [udiskie];
};
}