Replace swayidle with hypridle
This commit is contained in:
parent
2334582c33
commit
b4ae0e7547
|
@ -16,6 +16,24 @@ let
|
|||
}
|
||||
in {
|
||||
|
||||
services.hypridle.enable = true;
|
||||
services.hypridle.settings = {
|
||||
general = {
|
||||
before_sleep_cmd = "swaylock -f";
|
||||
};
|
||||
|
||||
listener = [
|
||||
{
|
||||
timeout = 120;
|
||||
on-timeout = "swaylock -f --grace=180"
|
||||
}
|
||||
{
|
||||
timeout = 600;
|
||||
on-timeout = "systemctl suspend";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
# Idle inhibiting
|
||||
|
||||
home.packages = [
|
||||
|
|
|
@ -5,8 +5,3 @@ swaybg -o '*' -i "$background" -m fill &
|
|||
|
||||
# Status Bar
|
||||
eww open "$platform"_bar --screen 0
|
||||
|
||||
# Idle Handler
|
||||
swayidle timeout 120 'swaylock -f --grace=180' \
|
||||
timeout 600 'systemctl suspend' \
|
||||
before-sleep 'swaylock -f' &
|
||||
|
|
Loading…
Reference in a new issue