Include customSettings option to configure regreet #4

Merged
MathewHDYT merged 6 commits from main into main 2024-11-08 19:41:51 +01:00
3 changed files with 15 additions and 3 deletions

View file

@ -88,7 +88,7 @@
]; ];
type = with lib.types; listOf attrs; type = with lib.types; listOf attrs;
description = '' description = ''
Adds modules to ironbar. Adds modules to ironbar. See https://github.com/JakeStanger/ironbar/wiki/ for more information.
''; '';
}; };
}; };

View file

@ -46,7 +46,7 @@
}; };
example = { }; example = { };
type = with lib.types; attrsOf anything; type = with lib.types; attrsOf anything;
description = "Firefox policy configuration"; description = "Firefox policy configuration. See https://mozilla.github.io/policy-templates/ for more information.";
}; };
extensions = lib.mkOption { extensions = lib.mkOption {
default = with pkgs.nur.repos.rycee.firefox-addons; [ default = with pkgs.nur.repos.rycee.firefox-addons; [

View file

@ -58,6 +58,16 @@
''; '';
}; };
}; };
regreet = {
customSettings = lib.mkOption {
default = { };
example = { };
type = with lib.types; attrsOf anything;
description = ''
Custom regret settings. See https://github.com/rharish101/ReGreet/blob/main/regreet.sample.toml for more information.
'';
};
};
}; };
config = config =
@ -120,11 +130,13 @@
env=XCURSOR_SIZE,${toString config.mods.stylix.cursor.size} env=XCURSOR_SIZE,${toString config.mods.stylix.cursor.size}
env=QT_QPA_PLATFORMTHEME,qt5ct env=QT_QPA_PLATFORMTHEME,qt5ct
exec-once=regreet --style /home/${username}/.config/gtk-3.0/gtk.css; hyprctl dispatch exit exec-once=regreet --style /home/${username}/.config/gtk-3.0/gtk.css --config /home/${username}/.config/regreet/regreet.toml; hyprctl dispatch exit
''; '';
# unlock GPG keyring on login # unlock GPG keyring on login
security.pam.services.greetd.enableGnomeKeyring = true; security.pam.services.greetd.enableGnomeKeyring = true;
} // lib.optionalAttrs (options ? home) {
xdg.configFile."regreet/regreet.toml".source = (pkgs.formats.toml { }).generate "regreet" config.mods.regreet.customSettings;
} }
); );
} }