Files
lnx-arch/dots/bin/i3lock_fk.sh

22 lines
824 B
Bash
Raw Normal View History

2024-05-19 17:35:37 -05:00
#!/usr/bin/env bash
# src:https://github.com/veltall/custom-i3lock
2024-05-19 18:18:28 -05:00
img_dir=/home/${USER}/.local/share/img
2024-05-19 18:52:11 -05:00
overlay_images=("ajp.png" "antiVax.png" "archLinux.png" "archLogo.png" "linuxLogo1.png" "linuxLogo2.png")
2024-05-19 18:55:25 -05:00
random_image_file=${overlay_images[ $RANDOM % ${#overlay_images[@]} ]}
random_image=${img_dir}/${random_image_file}
2024-05-19 17:46:08 -05:00
2024-05-19 17:48:18 -05:00
gravity=("center" "northwest" "northeast" "southwest" "southeast")
random_gravity=${gravity[ $RANDOM % ${#gravity[@]} ]}
2024-05-19 17:46:08 -05:00
2024-05-19 18:59:15 -05:00
notify-send "${random_image_file} @ ${random_gravity} ➔ coming up…"
2024-05-19 18:53:45 -05:00
#echo "${random_image}"
#echo "${random_gravity}"
2024-05-19 17:35:37 -05:00
2024-05-19 18:59:15 -05:00
scrot /tmp/currentworkspace.png
convert /tmp/currentworkspace.png -blur 0x8 /tmp/currentworkspaceblur.png
composite -gravity ${random_gravity} ${random_image} /tmp/currentworkspaceblur.png /tmp/lockbackground.png
i3lock -i /tmp/lockbackground.png