From d2c6a7b9a0460f99c2c202203952f129bfb8de1a Mon Sep 17 00:00:00 2001 From: Simon Bruder Date: Sat, 1 Feb 2020 21:51:47 +0000 Subject: [PATCH] Modify lock screen script to use current wallpaper --- roles/gui/files/lock | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/roles/gui/files/lock b/roles/gui/files/lock index 8961dc0..8ffb3e8 100755 --- a/roles/gui/files/lock +++ b/roles/gui/files/lock @@ -1,3 +1,8 @@ #!/bin/sh -i3lock -f -t -i /usr/share/wallpapers/lockscreen.png +if [ -e "$HOME/.fehbg" ]; then + image="$(tail -n 1 "$HOME/.fehbg" | cut -d' ' -f 4- | tail -c +2 | head -c -3)" +else + image="/usr/share/wallpapers/lockscreen.png" +fi +i3lock -f -t -i "$image" xset dpms force off