chore: reorganize desktop environment configuration
Cleanup existing desktop environment configuration to allow adding more desktop environments with shared configs. Signed-off-by: Chinmay D. Pai <chinmaydpai@gmail.com>
This commit is contained in:
parent
66e7dab5aa
commit
dfd6c1d42b
@ -4,7 +4,10 @@
|
||||
pkgs,
|
||||
...
|
||||
}: {
|
||||
options.snowflake.desktop.enable = lib.mkEnableOption "Enable core Desktop Environment configuration";
|
||||
options.snowflake.desktop = {
|
||||
enable = lib.mkEnableOption "Enable core Desktop Environment configuration";
|
||||
fingerprint.enable = lib.mkEnableOption "Enable fingerprint support for Desktop Environments";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.snowflake.desktop.enable {
|
||||
snowflake = {
|
||||
@ -41,6 +44,12 @@
|
||||
LIBVA_DRIVER_NAME = "iHD";
|
||||
};
|
||||
|
||||
# Enable fingerprint authentication.
|
||||
# Requires fingerprint registered using `fprint-enroll` to work.
|
||||
services.fprintd.enable = true;
|
||||
services.libinput.enable = true;
|
||||
|
||||
services.xserver.enable = true;
|
||||
# Prevents xterm from being installed.
|
||||
# Prefer installing a custom terminal emulator instead.
|
||||
services.xserver.excludePackages = [pkgs.xterm];
|
||||
@ -53,6 +62,13 @@
|
||||
# Additional configuration will be done through individual
|
||||
# desktop environment configurations.
|
||||
xdg.portal.enable = true;
|
||||
# Additional configuration for XDG Portal.
|
||||
xdg.portal.wlr.enable = true;
|
||||
xdg.portal.xdgOpenUsePortal = true;
|
||||
xdg.portal.extraPortals = with pkgs; [
|
||||
xdg-desktop-portal-gtk
|
||||
xdg-desktop-portal-kde
|
||||
];
|
||||
|
||||
# Set environment variables for the system.
|
||||
environment.variables = {
|
||||
|
@ -10,21 +10,12 @@
|
||||
|
||||
config = lib.mkIf config.snowflake.desktop.kde.enable {
|
||||
services = {
|
||||
libinput.enable = true;
|
||||
|
||||
xserver = {
|
||||
enable = true;
|
||||
};
|
||||
displayManager.sddm = {
|
||||
enable = true;
|
||||
wayland.enable = true;
|
||||
wayland.compositor = "kwin";
|
||||
};
|
||||
desktopManager.plasma6.enable = true;
|
||||
|
||||
# Enable fingerprint authentication.
|
||||
# Requires fingerprint registered using `fprint-enroll` to work.
|
||||
fprintd.enable = true;
|
||||
};
|
||||
|
||||
# Remove bloatware that we do not require.
|
||||
@ -39,11 +30,7 @@
|
||||
# SDDM does not work well with fingerprint authentication.
|
||||
security.pam.services.login.fprintAuth = false;
|
||||
|
||||
# Additional configuration for XDG Portal.
|
||||
xdg.portal.wlr.enable = true;
|
||||
xdg.portal.xdgOpenUsePortal = true;
|
||||
xdg.portal.extraPortals = with pkgs; [
|
||||
xdg-desktop-portal-gtk
|
||||
xdg-desktop-portal-kde
|
||||
];
|
||||
|
||||
|
@ -54,6 +54,7 @@
|
||||
core.docker.storageDriver = "btrfs";
|
||||
|
||||
desktop.enable = true;
|
||||
desktop.fingerprint.enable = true;
|
||||
desktop.kde.enable = true;
|
||||
|
||||
gaming.steam.enable = true;
|
||||
|
Loading…
Reference in New Issue
Block a user