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.
60 lines
1.5 KiB
Nix
60 lines
1.5 KiB
Nix
{
|
|
pkgs,
|
|
lib,
|
|
config,
|
|
inputs,
|
|
...
|
|
}:
|
|
let
|
|
schemesFile = import ./schemes.nix {
|
|
inherit pkgs inputs;
|
|
};
|
|
scheme = schemesFile.schemes.paul;
|
|
cfg = config.my.stylix;
|
|
gnomeEnabled = config.services.desktopManager.gnome.enable;
|
|
in
|
|
{
|
|
options.my.stylix = {
|
|
enable = lib.mkEnableOption "system-wide theming with Stylix";
|
|
users = lib.mkOption {
|
|
type = lib.types.either lib.types.str (lib.types.listOf lib.types.str);
|
|
default = config.my.toggleUsers.stylix;
|
|
description = "Users to apply Stylix theming for";
|
|
};
|
|
};
|
|
config = {
|
|
stylix = {
|
|
inherit (scheme) image polarity;
|
|
enable = true;
|
|
autoEnable = cfg.enable;
|
|
targets.qt.platform = lib.mkForce "qtct";
|
|
}
|
|
// lib.optionalAttrs (scheme ? base16Scheme) { inherit (scheme) base16Scheme; };
|
|
home-manager.users = inputs.self.lib.mkHomeManagerUsers lib config.my.stylix.users (user: {
|
|
gtk = lib.mkIf (!cfg.enable && gnomeEnabled) {
|
|
enable = true;
|
|
iconTheme = {
|
|
name = "Papirus-Light";
|
|
package = pkgs.papirus-icon-theme.override {
|
|
color = "yellow";
|
|
};
|
|
};
|
|
};
|
|
stylix = {
|
|
inherit (cfg) enable;
|
|
autoEnable = cfg.enable;
|
|
iconTheme = {
|
|
inherit (cfg) enable;
|
|
package = scheme.iconPackage;
|
|
light = "Papirus-Light";
|
|
dark = "Papirus-Dark";
|
|
};
|
|
targets.librewolf = {
|
|
firefoxGnomeTheme.enable = true;
|
|
profileNames = [ user ];
|
|
};
|
|
};
|
|
});
|
|
};
|
|
}
|