diff --git a/.config/hypr/hypridle.conf b/.config/hypr/hypridle.conf index 32691ba..e235a7e 100644 --- a/.config/hypr/hypridle.conf +++ b/.config/hypr/hypridle.conf @@ -1,12 +1,13 @@ general { - lock_cmd = hyprlock & $HOME/.scripts/theme-changer.sh album sfw - before_sleep_cmd = hyprlock & $HOME/.scripts/theme-changer.sh album sfw + lock_cmd = pgrep -u "$USER" hyprlock || (hyprlock & sleep 0.5 && $HOME/.scripts/theme-changer.sh album sfw) + before_sleep_cmd = loginctl lock-session + after_sleep_cmd = hyprctl dispatch dpms on } # Lock after 5min listener { timeout = 300 - on-timeout = hyprlock & $HOME/.scripts/theme-changer.sh album sfw + on-timeout = loginctl lock-session } # Turn of screen after 6min