From 52c49bc422fb50a7e318c614eba8ee3197e5d733 Mon Sep 17 00:00:00 2001 From: James Patrick Date: Wed, 23 Mar 2022 22:29:13 -0400 Subject: [PATCH] Added Display Manager so I half to deal with less. --- modules/system/default.nix | 1 + modules/system/displaymanager.nix | 27 +++++++++++++++++++++++++++ 2 files changed, 28 insertions(+) create mode 100644 modules/system/displaymanager.nix diff --git a/modules/system/default.nix b/modules/system/default.nix index 7e6a526..fb97bd2 100644 --- a/modules/system/default.nix +++ b/modules/system/default.nix @@ -2,6 +2,7 @@ imports = [ ./boot.nix ./cli.nix + ./displaymanager.nix ./flatpak.nix ./fonts.nix ./gtk.nix diff --git a/modules/system/displaymanager.nix b/modules/system/displaymanager.nix new file mode 100644 index 0000000..95b79d5 --- /dev/null +++ b/modules/system/displaymanager.nix @@ -0,0 +1,27 @@ +{ config, lib, pkgs, ... }: +let + cfg = config.systems.displaymanager; + graphical = config.this.graphical; +in with lib; { + options = { + systems.displaymanager = { + enable = mkOption { + default = graphical.enable; + type = with types; bool; + }; + }; + }; + + config = mkIf cfg.enable { + services.xserver = { + enable = true; + displayManager = { + autoLogin = { + enable = true; + user = "james"; + }; + gdm.enable = true; + }; + }; + }; +}