diff options
author | Tim Keller <tjk@tjkeller.xyz> | 2024-10-02 21:29:37 -0500 |
---|---|---|
committer | Tim Keller <tjk@tjkeller.xyz> | 2024-10-02 21:29:37 -0500 |
commit | 34b0bb8df42194a0ea433592e3cac27546f0af4e (patch) | |
tree | f584369db3a6accb74b1a9288c2480f8fd411671 /modules/x11/default.nix | |
parent | 4e4b8068825044ebfd435ec8a6f0e84f5c0c8801 (diff) | |
download | nixos-34b0bb8df42194a0ea433592e3cac27546f0af4e.tar.xz nixos-34b0bb8df42194a0ea433592e3cac27546f0af4e.zip |
modularize conf and stuff
Diffstat (limited to 'modules/x11/default.nix')
-rw-r--r-- | modules/x11/default.nix | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/modules/x11/default.nix b/modules/x11/default.nix new file mode 100644 index 0000000..8fa1d27 --- /dev/null +++ b/modules/x11/default.nix @@ -0,0 +1,30 @@ +{ pkgs, lib, config, ... }: { + options = { + xserver.enable = lib.mkEnableOption "enables xserver"; + }; + + config = lib.mkIf config.xserver.enable { + services.xserver.enable = true; + services.xserver.displayManager.startx.enable = true; + services.libinput.enable = true; # Enable touchpad support + + environment.systemPackages = with pkgs; [ + unclutter + xcape + xclip + xdotool + xorg.setxkbmap + xorg.xinput + xorg.xkill + xorg.xrandr + xorg.xset + xwallpaper + # Patch startx to be compliant with xdg base dir spec + (xorg.xinit.overrideAttrs (old: rec { + patches = [ + ./xinit-startx-xdg.patch + ]; + })) + ]; + }; +} |