Add gnome GUI

This commit is contained in:
Jakob Lechner 2024-05-13 14:22:04 +00:00
parent c38432e2a0
commit 5d78f0fc9c
4 changed files with 23 additions and 2 deletions

View file

@ -23,6 +23,7 @@
bluetooth.enable = true; bluetooth.enable = true;
uefi.enable = true; uefi.enable = true;
gui.enable = true; gui.enable = true;
gui.desktop = "gnome";
workstation.enable = true; workstation.enable = true;
sdr.enable = false; sdr.enable = false;
#autologin.enable = true; #autologin.enable = true;

View file

@ -2,7 +2,14 @@
{ {
options.jalr = { options.jalr = {
gui.enable = lib.mkEnableOption "GUI"; gui = {
enable = lib.mkEnableOption "GUI";
desktop = lib.mkOption {
type = lib.types.nullOr (lib.types.enum [ "sway" "gnome" ]);
default = "sway";
description = "Desktop environment to install";
};
};
workstation.enable = lib.mkEnableOption "Workstation"; workstation.enable = lib.mkEnableOption "Workstation";
}; };
@ -17,6 +24,7 @@
./dnsmasq.nix ./dnsmasq.nix
./fish.nix ./fish.nix
./fonts.nix ./fonts.nix
./gnome.nix
./journald.nix ./journald.nix
./kdeconnect.nix ./kdeconnect.nix
./kvm-switch-enable-screen.nix ./kvm-switch-enable-screen.nix

12
modules/gnome.nix Normal file
View file

@ -0,0 +1,12 @@
{ config, lib, pkgs, ... }:
lib.mkIf (config.jalr.gui.enable && config.jalr.gui.desktop == "gnome") {
services.xserver = {
enable = true;
desktopManager.gnome.enable = true;
displayManager.gdm = {
enable = true;
autoSuspend = false;
};
};
}

View file

@ -1,6 +1,6 @@
{ config, lib, pkgs, ... }: { config, lib, pkgs, ... }:
lib.mkIf config.jalr.gui.enable { lib.mkIf (config.jalr.gui.enable && config.jalr.gui.desktop == "sway") {
programs.sway = { programs.sway = {
enable = true; enable = true;
# FIXME: move to home manager # FIXME: move to home manager