Enhanced the configuration files to support multi-user management by introducing user options for multiple applications, including art, gaming, multimedia, and development tools. Updated existing modules to utilize these new user options, improving flexibility and maintainability in user package installations.
33 lines
710 B
Nix
33 lines
710 B
Nix
{
|
|
config,
|
|
inputs,
|
|
lib,
|
|
pkgs,
|
|
...
|
|
}:
|
|
let
|
|
packages = builtins.attrValues {
|
|
inherit (pkgs)
|
|
hunspell
|
|
;
|
|
inherit (pkgs.hunspellDicts)
|
|
it_IT
|
|
es_MX
|
|
en_CA-large
|
|
;
|
|
};
|
|
in
|
|
{
|
|
options.my.apps.dictionaries = {
|
|
enable = lib.mkEnableOption "dictionaries and language tools";
|
|
users = lib.mkOption {
|
|
type = lib.types.either lib.types.str (lib.types.listOf lib.types.str);
|
|
default = config.my.toggleUsers.apps;
|
|
description = "Users to install dictionaries packages for";
|
|
};
|
|
};
|
|
config = lib.mkIf config.my.apps.dictionaries.enable {
|
|
users.users = inputs.self.lib.mkUserPackages lib config.my.apps.dictionaries.users packages;
|
|
};
|
|
}
|