parent
9e96d809d3
commit
b838caa222
5 changed files with 144 additions and 101 deletions
|
@ -12,12 +12,10 @@ with lib;
|
|||
default = config.components.gui.enable;
|
||||
};
|
||||
|
||||
config = mkIf (config.components.gui.audio.enable) {
|
||||
config = mkMerge [
|
||||
(mkIf (config.components.gui.audio.enable) {
|
||||
|
||||
security.rtkit.enable = true;
|
||||
|
||||
services.pulseaudio.enable = false;
|
||||
|
||||
hardware.bluetooth = {
|
||||
enable = true;
|
||||
powerOnBoot = true;
|
||||
|
@ -34,7 +32,7 @@ with lib;
|
|||
];
|
||||
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
#enable = true;
|
||||
systemWide = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
|
@ -52,5 +50,16 @@ with lib;
|
|||
}
|
||||
'';
|
||||
};
|
||||
};
|
||||
})
|
||||
|
||||
{
|
||||
|
||||
# this is always true
|
||||
# seems other options enable this one
|
||||
services.pipewire.enable = config.components.gui.audio.enable;
|
||||
services.pulseaudio.enable = false;
|
||||
|
||||
}
|
||||
|
||||
];
|
||||
}
|
||||
|
|
|
@ -16,6 +16,7 @@ with lib;
|
|||
./browser.nix
|
||||
./cups.nix
|
||||
./home-manager
|
||||
./kde.nix
|
||||
./kmonad.nix
|
||||
./noti.nix # todo: make this different (use password store and such)
|
||||
./pass.nix
|
||||
|
|
19
components/gui/kde.nix
Normal file
19
components/gui/kde.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}:
|
||||
{
|
||||
|
||||
options.components.gui.kde.enable = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
default = config.components.gui.enable;
|
||||
};
|
||||
|
||||
config = lib.mkIf (config.components.gui.kde.enable) {
|
||||
|
||||
services.desktopManager.plasma6.enable = true;
|
||||
|
||||
};
|
||||
}
|
|
@ -14,30 +14,41 @@ with lib;
|
|||
default = config.components.gui.enable;
|
||||
};
|
||||
|
||||
config = mkIf (config.components.gui.xorg.enable && config.components.gui.enable) {
|
||||
options.components.gui.xorg.lightdm.enable = mkOption {
|
||||
type = lib.types.bool;
|
||||
default = config.components.gui.xorg.enable;
|
||||
};
|
||||
|
||||
options.components.gui.xorg.sddm.enable = mkOption {
|
||||
type = lib.types.bool;
|
||||
default = !config.components.gui.xorg.lightdm.enable;
|
||||
};
|
||||
|
||||
config = mkMerge [
|
||||
|
||||
(mkIf (config.components.gui.xorg.lightdm.enable && config.components.gui.xorg.enable) {
|
||||
|
||||
# system.custom.fonts.enable = true;
|
||||
services.displayManager = {
|
||||
defaultSession = lib.mkDefault "none+i3";
|
||||
defaultSession = "none+i3";
|
||||
autoLogin.enable = lib.mkDefault true;
|
||||
autoLogin.user = config.users.users.mainUser.name;
|
||||
};
|
||||
|
||||
services.xserver = {
|
||||
services.xserver.displayManager.lightdm.enable = true;
|
||||
|
||||
enable = true;
|
||||
})
|
||||
|
||||
displayManager = {
|
||||
lightdm.enable = lib.mkDefault true;
|
||||
};
|
||||
(mkIf (config.components.gui.xorg.sddm.enable && config.components.gui.xorg.enable) {
|
||||
|
||||
desktopManager.xterm.enable = false;
|
||||
windowManager.i3.enable = true;
|
||||
services.xserver.displayManager.sddm.enable = true;
|
||||
|
||||
# mouse/touchpad
|
||||
# --------------
|
||||
})
|
||||
|
||||
};
|
||||
(mkIf (config.components.gui.xorg.enable && config.components.gui.enable) {
|
||||
|
||||
services.xserver.enable = true;
|
||||
|
||||
services.xserver.windowManager.i3.enable = true;
|
||||
|
||||
services.libinput = {
|
||||
enable = true;
|
||||
|
@ -81,5 +92,7 @@ with lib;
|
|||
'';
|
||||
environment.etc."/X11/Xresource.d/.keep".text = "";
|
||||
|
||||
};
|
||||
})
|
||||
|
||||
];
|
||||
}
|
||||
|
|
|
@ -55,6 +55,7 @@
|
|||
components.virtualisation.enable = true;
|
||||
|
||||
components.gui.enable = true;
|
||||
components.gui.audio.enable = false;
|
||||
components.mainUser.enable = true;
|
||||
components.media.enable = true;
|
||||
components.media.tts-client.enable = false;
|
||||
|
|
Loading…
Add table
Reference in a new issue