Add swaylock-effects lock via lock.sh with fallback
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -28,7 +28,7 @@ client.background $base
|
||||
# Autostart
|
||||
exec_always sh -c 'pkill -x dunst; exec dunst'
|
||||
exec_always sh -c 'pkill -x nm-applet; exec nm-applet --indicator'
|
||||
bindsym $mod+Shift+x exec swaylock -f
|
||||
bindsym $mod+Shift+x exec ~/.config/sway/lock.sh
|
||||
|
||||
# Touchpad
|
||||
input type:touchpad {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/bin/sh
|
||||
pkill -x swayidle
|
||||
exec swayidle -w \
|
||||
timeout 300 'swaylock -f' \
|
||||
timeout 300 "$HOME/.config/sway/lock.sh" \
|
||||
timeout 600 'swaymsg "output * power off"' resume 'swaymsg "output * power on"' \
|
||||
before-sleep 'swaylock -f'
|
||||
before-sleep "$HOME/.config/sway/lock.sh"
|
||||
|
||||
Executable
+8
@@ -0,0 +1,8 @@
|
||||
#!/bin/sh
|
||||
# Lock with swaylock-effects (blur + clock) if installed, else plain swaylock.
|
||||
pgrep -x swaylock >/dev/null && exit 0
|
||||
fx=$HOME/.local/bin/swaylock-effects
|
||||
if [ -x "$fx" ]; then
|
||||
exec "$fx" -f -C "$HOME/.config/swaylock/config-effects"
|
||||
fi
|
||||
exec swaylock -f
|
||||
Reference in New Issue
Block a user