Reworked home manager configuration to modules
This commit is contained in:
29
modules/home/theming/fonts.nix
Normal file
29
modules/home/theming/fonts.nix
Normal file
@@ -0,0 +1,29 @@
|
||||
{ config, lib, pkgs, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.settings.theming.fonts;
|
||||
in {
|
||||
options = {
|
||||
settings.theming.fonts.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
description = ''
|
||||
Enable fonts
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
fonts.fontconfig.enable = true;
|
||||
|
||||
home.packages = with pkgs; [
|
||||
noto-fonts
|
||||
fira-code
|
||||
font-awesome
|
||||
dejavu_fonts
|
||||
roboto
|
||||
(nerdfonts.override { fonts = [ "DejaVuSansMono" ]; })
|
||||
];
|
||||
};
|
||||
}
|
55
modules/home/theming/nix-colors.nix
Normal file
55
modules/home/theming/nix-colors.nix
Normal file
@@ -0,0 +1,55 @@
|
||||
{ config, nix-colors, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
let
|
||||
cfg = config.settings.theming.nix-colors;
|
||||
inherit
|
||||
(nix-colors.lib-contrib { inherit pkgs; })
|
||||
gtkThemeFromScheme;
|
||||
in {
|
||||
options = {
|
||||
settings.theming.nix-colors.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
description = ''
|
||||
Enable nix colors configuration
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
imports = [
|
||||
nix-colors.homeManagerModules.default
|
||||
];
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
colorScheme = nix-colors.colorSchemes.da-one-sea;
|
||||
|
||||
gtk = lib.mkIf (config.headless == false) {
|
||||
enable = true;
|
||||
theme = {
|
||||
name = "${config.colorScheme.slug}";
|
||||
package = gtkThemeFromScheme { scheme = config.colorScheme; };
|
||||
};
|
||||
iconTheme = {
|
||||
package = pkgs.qogir-icon-theme;
|
||||
name = "Qogir-dark";
|
||||
};
|
||||
};
|
||||
|
||||
qt = lib.mkIf (config.headless == false) {
|
||||
enable = true;
|
||||
platformTheme.name = "gtk";
|
||||
style = {
|
||||
name = "gtk2";
|
||||
package = pkgs.qt6Packages.qt6gtk2;
|
||||
};
|
||||
};
|
||||
|
||||
home.pointerCursor = lib.mkIf (config.headless == false) {
|
||||
package = pkgs.phinger-cursors;
|
||||
name = "phinger-cursors-dark";
|
||||
size = 24;
|
||||
gtk.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
Reference in New Issue
Block a user