-if [ -x /usr/bin/xscreensaver -a -e ~/.xscreensaver ]; then
- ( XENVIRONMENT=~/.xscreensaver /usr/bin/xscreensaver >/dev/null 2>&1 &)
-elif [ -x /usr/bin/xautolock ]; then
- (/usr/bin/xautolock -notifier true -bell 0 >/de/vnull 2>&1 &)
+if [ -e ~/bin/screensaver ]; then
+ ~/bin/screensaver on;
+elif cmd_exists i3lock && cmd_exists xss-lock; then
+ fork xss-lock -l -- ~/bin/locker
+elif cmd_exists slock && cmd_exists xautolock; then
+ fork xautolock -notifier true -bell 0 -locker slock;
+ if cmd_exists xss-lock; then
+ fork xss-lock -- xautolock -locknow;
+ fi;
+elif cmd_exists xscreensaver && [ -e ~/.xscreensaver ]; then
+ fork XENVIRONMENT=~/.xscreensaver /usr/bin/xscreensaver;
+elif cmd_exists xautolock; then
+ fork xautolock -notifier true -bell 0;
+ if cmd_exists xss-lock; then
+ fork xss-lock -- xautolock -locknow;
+ fi;