31 lines
723 B
Nix
31 lines
723 B
Nix
{
|
|
pkgs,
|
|
lib,
|
|
...
|
|
}: {
|
|
services.swayosd.enable = true;
|
|
|
|
# Auto-restart swayosd on crash
|
|
systemd.user.services.swayosd = {
|
|
Unit = {
|
|
StartLimitBurst = lib.mkForce 5;
|
|
StartLimitIntervalSec = lib.mkForce 30;
|
|
};
|
|
Service = {
|
|
Restart = lib.mkForce "on-failure";
|
|
RestartSec = lib.mkForce "100ms";
|
|
};
|
|
};
|
|
|
|
wayland.windowManager.hyprland.settings = {
|
|
bindel = [
|
|
", XF86AudioRaiseVolume, exec, swayosd-client --output-volume raise"
|
|
", XF86AudioLowerVolume, exec, swayosd-client --output-volume lower"
|
|
];
|
|
bindl = [
|
|
", XF86AudioMute, exec, swayosd-client --output-volume mute-toggle"
|
|
", Caps_Lock, exec, swayosd-client --caps-lock"
|
|
];
|
|
};
|
|
}
|