diff --git a/modules/home/desktop/sway/sway.nix b/modules/home/desktop/sway/sway.nix index 4214769..a6266d9 100644 --- a/modules/home/desktop/sway/sway.nix +++ b/modules/home/desktop/sway/sway.nix @@ -1,4 +1,4 @@ -{ pkgs, config, ...}: +{ pkgs, config, hostConfig, ...}: { wayland.windowManager.sway = { enable = true; @@ -89,8 +89,8 @@ "${mod}+a" = "focus parent"; "${mod}+Shift+p" = "move scratchpad"; "${mod}+p" = "scratchpad show"; - "${mod}+F1" = "exec brightnessctl s 1%-"; - "${mod}+F2" = "exec brightnessctl s +1%"; + "${mod}+F1" = (if hostConfig.laptop then "${pkgs.brightnessctl}/bin/brightnessctl s 1%-" else null); + "${mod}+F2" = (if hostConfig.laptop then "${pkgs.brightnessctl}/bin/brightnessctl s +1%" else null); "${mod}+F3" = "exec pactl set-sink-volume @DEFAULT_SINK@ -5%"; "${mod}+F4" = "exec pactl set-sink-volume @DEFAULT_SINK@ +5%"; "${mod}+F5" = "exec pactl set-sink-mute @DEFAULT_SINK@ toggle";