refactor: move qt and sddm to common

This commit is contained in:
LordGrimmauld 2024-04-16 12:25:00 +02:00
parent d250dc13ef
commit e96da4ea8a
8 changed files with 42 additions and 40 deletions

View file

@ -39,6 +39,7 @@ in
extraPackages = with pkgs; [ ];
};
chaotic.mesa-git.enable = true;
boot.kernelParams = [ "nouveau.config=NvGspRm=1" ];
environment.sessionVariables = {

37
common/qt.nix Normal file
View file

@ -0,0 +1,37 @@
{ pkgs, lib, config, ... }:
let
cfg = config.grimmShared;
in
{
config = with cfg; lib.mkIf (enable && graphical) {
qt = {
enable = true;
style = "kvantum";
platformTheme = "qt5ct";
};
environment.systemPackages = with pkgs; [
libsForQt5.qtstyleplugin-kvantum
catppuccin-kvantum
catppuccin-sddm-corners
libsForQt5.qtgraphicaleffects
catppuccin-kvantum
kdePackages.audiocd-kio
xcb-util-cursor
qt6ct
libsForQt5.dolphin
];
# environment.etc."kvantum".source = "${pkgs.catppuccin-kvantum}/share/Kvantum";
services.displayManager = {
sddm = {
enable = true;
theme = "catppuccin-sddm-corners";
wayland.enable = true;
wayland.compositor = "weston";
};
defaultSession = lib.optionalString cfg.sway.enable "sway";
};
};
}

View file

@ -40,8 +40,8 @@ in
let
waybar_full = pkgs.writeShellScriptBin "waybar-full" (
(lib.getExe config.programs.waybar.package)
+ (if isNull cfg.sway.bar.config then "" else " -c ${cfg.sway.bar.config}")
+ (if isNull cfg.sway.bar.style then "" else " -s ${cfg.sway.bar.style}")
+ (lib.optionalString (!isNull cfg.sway.bar.config) " -c ${cfg.sway.bar.config}")
+ (lib.optionalString (!isNull cfg.sway.bar.style) " -s ${cfg.sway.bar.style}")
);
bar_config = ''

View file

@ -24,7 +24,7 @@
# Enable flatpaks
services.flatpak.enable = true;
chaotic.mesa-git.enable = true;
services.ddccontrol.enable = true;
powerManagement.scsiLinkPolicy = "min_power";
hardware.i2c.enable = true;
@ -65,23 +65,6 @@
mode = "777";
};
qt = {
enable = true;
style = "kvantum";
platformTheme = "qt5ct";
};
environment.systemPackages = with pkgs; [
libsForQt5.qtstyleplugin-kvantum
catppuccin-kvantum
catppuccin-sddm-corners
libsForQt5.qtgraphicaleffects
catppuccin-kvantum
qt6ct
];
# environment.etc."kvantum".source = "${pkgs.catppuccin-kvantum}/share/Kvantum";
environment.sessionVariables = {
NIXPKGS_ALLOW_UNFREE = "1";
MOZ_ENABLE_WAYLAND = "1";

View file

@ -42,7 +42,6 @@
./configuration.nix
./modules/users.nix
./modules/spotify-tui.nix
./modules/xserver.nix
./modules/system-packages.nix
./modules/kvm.nix
{ environment.systemPackages = [ agenix.packages.${system}.default ]; }

View file

@ -18,5 +18,6 @@ with lib;
./common/sway.nix
./common/cloudsync.nix
./common/security.nix
./common/qt.nix
];
}

View file

@ -1,9 +1,6 @@
{ pkgs, ... }: {
environment.systemPackages = with pkgs; [
oci-cli
xcb-util-cursor
krfb
kdePackages.audiocd-kio
(writeShellScriptBin "rebuild" "nixos-rebuild switch --flake .")
];
}

View file

@ -1,16 +0,0 @@
{
services.displayManager = {
# lightdm.enable = true;
sddm = {
enable = true;
theme = "catppuccin-sddm-corners";
wayland.enable = true;
wayland.compositor = "weston";
};
defaultSession = "sway";
};
services.desktopManager = {
# plasma6.enable = true;
};
}