config/modules/home/wms/sway/default.nix

63 lines
1.4 KiB
Nix
Raw Normal View History

{
lib,
config,
pkgs,
2024-08-07 10:44:50 -04:00
inputs,
...
}:
with lib;
with lib.custom; let
cfg = config.wms.sway;
mkService = recursiveUpdate {
Unit.PartOf = ["graphical-session.target"];
Unit.After = ["graphical-session.target"];
Install.WantedBy = ["graphical-session.target"];
};
in {
options.wms.sway = with types; {
enable = mkBoolOpt false "Enable Sway";
};
2025-05-28 16:55:13 -04:00
config = mkIf (cfg.enable && !pkgs.stdenv.isDarwin) {
wayland.windowManager.sway = {
enable = true;
xwayland = true;
2024-09-23 19:22:17 -04:00
package = inputs.nixpkgs-wayland.packages.${pkgs.system}.sway-unwrapped;
extraOptions = ["--unsupported-gpu"];
config = {
2024-09-23 19:22:17 -04:00
terminal = "foot";
startup = [{command = "zen";} {command = "vesktop";} {command = "slack";} {command = "telegram-desktop";} {command = "thunderbird";}];
menu = "killall anyrun || anyrun";
2024-08-21 14:35:32 -04:00
modifier = "Mod4";
input = {
"Logitech USB Receiver Keyboard" = {
accel_profile = "flat";
pointer_accel = "0";
};
"Logitech USB Receiver" = {
accel_profile = "flat";
pointer_accel = "0";
};
};
output = {
DP-1 = {
mode = "2560x1440@240Hz";
adaptive_sync = "off";
};
HDMI-A-1 = {
disable = "disable";
};
};
};
};
2025-05-28 19:10:50 -04:00
services.wallpaper.enable = true;
};
}