diff --git a/hosts/modules/desktop.nix b/hosts/modules/desktop.nix index 23c00b5..8930117 100644 --- a/hosts/modules/desktop.nix +++ b/hosts/modules/desktop.nix @@ -1,17 +1,45 @@ { config, pkgs, inputs, ... }: { # Enable the X11 windowing system. - services.xserver.enable = true; + services.xserver = { + enable = true; + xkb = { + layout = "us"; + variant = "dvorak"; + }; + + displayManager.gdm = { + enable = true; + wayland = true; + }; + }; + + # enable sway + programs.sway = { + enable = true; + wrapperFeatures.gtk = true; + }; + + # 2. Inject the Dvorak config into /etc/sway/config.d/ + # The default Sway config automatically includes files in this folder. + environment.etc."sway/config.d/99-dvorak.conf".text = '' + input * { + xkb_layout "us" + xkb_variant "dvorak" + } + ''; + + + # Essential System Services for Sway + # (Sway doesn't autostart these like GNOME does, so you need them enabled + # system-wide) + security.polkit.enable = true; # For permission popups + services.gnome.gnome-keyring.enable = true; # For saving wifi/login passwords + + services.desktopManager.gnome.enable = true; # Enable the GNOME Desktop Environment. - services.xserver.displayManager.gdm.enable = true; - services.xserver.desktopManager.gnome.enable = true; - - # Configure keymap in X11 - services.xserver.xkb = { - layout = "us"; - variant = "dvorak"; - }; + services.displayManager.gdm.enable = true; # enable japanese input i18n.inputMethod = { @@ -39,6 +67,12 @@ environment.systemPackages = with pkgs; [ bitwarden-desktop libreoffice-fresh + + # sway stuff + grim # screenshot functionality + slurp # screenshot functionality + wl-clipboard # wl-copy and wl-paste for copy/paste from stdin / stdout + mako # notification system developed by swaywm maintainer ]; # Enable networking