refactored theme configuration to use stylix instead of individually theming each program
This commit is contained in:
@@ -6,22 +6,22 @@
|
||||
username,
|
||||
host,
|
||||
...
|
||||
}:
|
||||
|
||||
let
|
||||
desktop_modules = if (host == "oganesson") then [
|
||||
./software/virtualization.nix
|
||||
] else [ ];
|
||||
in
|
||||
{
|
||||
}: let
|
||||
desktop_modules =
|
||||
if (host == "oganesson")
|
||||
then [
|
||||
./software/virtualization.nix
|
||||
]
|
||||
else [];
|
||||
in {
|
||||
imports =
|
||||
[(import ./hardware/bootloader.nix)]
|
||||
++ [(import ./hardware/network.nix)]
|
||||
++ [(import ./software/fonts.nix)]
|
||||
++ [(import ./software/sddm.nix)]
|
||||
++ [(import ./software/packages.nix)]
|
||||
++ [(import ./software/programs.nix)]
|
||||
++ [(import ./software/services.nix)]
|
||||
++ [(import ./software/users.nix)]
|
||||
++ [(import ./environment/sddm.nix)]
|
||||
++ [(import ./environment/users.nix)]
|
||||
++ [(import ./environment/stylix.nix)]
|
||||
++ desktop_modules;
|
||||
}
|
||||
|
||||
12
modules/sys/environment/sddm.nix
Normal file
12
modules/sys/environment/sddm.nix
Normal file
@@ -0,0 +1,12 @@
|
||||
{
|
||||
pkgs,
|
||||
self,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
package = pkgs.kdePackages.sddm;
|
||||
};
|
||||
}
|
||||
36
modules/sys/environment/stylix.nix
Normal file
36
modules/sys/environment/stylix.nix
Normal file
@@ -0,0 +1,36 @@
|
||||
{
|
||||
pkgs,
|
||||
self,
|
||||
...
|
||||
}: {
|
||||
stylix = {
|
||||
enable = true;
|
||||
base16Scheme = "${pkgs.base16-schemes}/share/themes/material-darker.yaml";
|
||||
image = ../../../media/wallpapers/catppuccin/cat-leaves.png;
|
||||
polarity = "dark";
|
||||
autoEnable = true;
|
||||
targets = {
|
||||
console.enable = true;
|
||||
feh.enable = true;
|
||||
grub.enable = true;
|
||||
};
|
||||
cursor = {
|
||||
package = pkgs.bibata-cursors;
|
||||
name = "Bibata-Modern-Ice";
|
||||
};
|
||||
fonts = {
|
||||
monospace = {
|
||||
package = pkgs.nerdfonts.override {fonts = ["JetBrainsMono"];};
|
||||
name = "JetBrainsMono Nerd Font Mono";
|
||||
};
|
||||
sansSerif = {
|
||||
package = pkgs.dejavu_fonts;
|
||||
name = "DejaVu Sans";
|
||||
};
|
||||
serif = {
|
||||
package = pkgs.dejavu_fonts;
|
||||
name = "DejaVu Serif";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
53
modules/sys/environment/users.nix
Normal file
53
modules/sys/environment/users.nix
Normal file
@@ -0,0 +1,53 @@
|
||||
{
|
||||
config,
|
||||
inputs,
|
||||
pkgs,
|
||||
username,
|
||||
self,
|
||||
host,
|
||||
...
|
||||
}: let
|
||||
nur = config.nur;
|
||||
in {
|
||||
imports = [inputs.home-manager.nixosModules.home-manager];
|
||||
home-manager = {
|
||||
useUserPackages = true;
|
||||
useGlobalPkgs = true;
|
||||
backupFileExtension = "backup";
|
||||
extraSpecialArgs = {inherit self inputs host username nur;};
|
||||
users.${username} = {
|
||||
dconf.settings = {
|
||||
"org/virt-manager/virt-manager/connections" = {
|
||||
autoconnect = ["qemu:///system"];
|
||||
uris = ["qemu:///system"];
|
||||
};
|
||||
};
|
||||
programs.home-manager.enable = true;
|
||||
imports = [
|
||||
./../../home
|
||||
];
|
||||
home = {
|
||||
username = "${username}";
|
||||
homeDirectory = "/home/${username}";
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
users = {
|
||||
groups.persist = {};
|
||||
users = {
|
||||
root.initialPassword = "1234";
|
||||
${username} = {
|
||||
isNormalUser = true;
|
||||
initialPassword = "1234";
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = ["wheel" "persist" "libvirtd"];
|
||||
};
|
||||
};
|
||||
};
|
||||
security.sudo.extraConfig = ''
|
||||
${username} ALL=(ALL) NOPASSWD: /run/current-system/sw/bin/nixos-rebuild
|
||||
'';
|
||||
nix.settings.allowed-users = ["${username}"];
|
||||
}
|
||||
@@ -1,7 +0,0 @@
|
||||
{pkgs, ...}: {
|
||||
fonts.packages = with pkgs; [
|
||||
times-newer-roman
|
||||
nerdfonts
|
||||
jetbrains-mono
|
||||
];
|
||||
}
|
||||
@@ -38,13 +38,13 @@
|
||||
mullvad
|
||||
mesa
|
||||
neofetch
|
||||
nh
|
||||
nh
|
||||
nix-index
|
||||
nix-output-monitor
|
||||
nix-output-monitor
|
||||
nix-prefetch-scripts
|
||||
nixos-option
|
||||
nix-search-cli
|
||||
nvd
|
||||
nvd
|
||||
openssl
|
||||
p7zip
|
||||
jq
|
||||
@@ -56,7 +56,6 @@
|
||||
protonmail-bridge
|
||||
protontricks
|
||||
pyright
|
||||
quintom-cursor-theme
|
||||
socat
|
||||
sox
|
||||
stress
|
||||
@@ -74,6 +73,6 @@
|
||||
xpad
|
||||
libnotify
|
||||
file
|
||||
libvirt-glib
|
||||
libvirt-glib
|
||||
];
|
||||
}
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
{
|
||||
pkgs,
|
||||
self,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = [
|
||||
(
|
||||
pkgs.catppuccin-sddm.override {
|
||||
flavor = "mocha";
|
||||
font = "JetBrains Mono";
|
||||
fontSize = "9";
|
||||
background = "${self}/media/wallpapers/catppuccin/nixos-catppuccin.png";
|
||||
}
|
||||
)
|
||||
];
|
||||
services.displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
theme = "catppuccin-mocha";
|
||||
package = pkgs.kdePackages.sddm;
|
||||
};
|
||||
}
|
||||
@@ -1,57 +0,0 @@
|
||||
{
|
||||
config,
|
||||
inputs,
|
||||
pkgs,
|
||||
username,
|
||||
self,
|
||||
host,
|
||||
...
|
||||
}: let
|
||||
nur = config.nur;
|
||||
in {
|
||||
imports = [inputs.home-manager.nixosModules.home-manager];
|
||||
home-manager = {
|
||||
useUserPackages = true;
|
||||
useGlobalPkgs = true;
|
||||
backupFileExtension = "backup";
|
||||
extraSpecialArgs = {inherit self inputs host username nur;};
|
||||
users.${username} = {
|
||||
dconf.settings = {
|
||||
"org/virt-manager/virt-manager/connections" = {
|
||||
autoconnect = ["qemu:///system"];
|
||||
uris = ["qemu:///system"];
|
||||
};
|
||||
};
|
||||
programs.home-manager.enable = true;
|
||||
imports = [
|
||||
./../../home
|
||||
];
|
||||
home = {
|
||||
username = "${username}";
|
||||
homeDirectory = "/home/${username}";
|
||||
stateVersion = "24.05";
|
||||
pointerCursor = {
|
||||
name = "Quintom_Ink";
|
||||
size = 36;
|
||||
package = pkgs.quintom-cursor-theme;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
users = {
|
||||
groups.persist = {};
|
||||
users = {
|
||||
root.initialPassword = "1234";
|
||||
${username} = {
|
||||
isNormalUser = true;
|
||||
initialPassword = "1234";
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = ["wheel" "persist" "libvirtd"];
|
||||
};
|
||||
};
|
||||
};
|
||||
security.sudo.extraConfig = ''
|
||||
${username} ALL=(ALL) NOPASSWD: /run/current-system/sw/bin/nixos-rebuild
|
||||
'';
|
||||
nix.settings.allowed-users = ["${username}"];
|
||||
}
|
||||
@@ -1,6 +1,4 @@
|
||||
{ username, ... }:
|
||||
|
||||
{
|
||||
virtualisation.libvirtd.enable = true;
|
||||
programs.virt-manager.enable = true;
|
||||
{username, ...}: {
|
||||
virtualisation.libvirtd.enable = true;
|
||||
programs.virt-manager.enable = true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user