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

20 lines
870 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 20:17:40 -05:00
overlay_images=("ajp.png" "amiga.png" "antiVax.png" "archLinux.png" "archLogo.png" "linuxLogo1.png" "linuxLogo2.png" "neon1.png" "neon2.png" "rickroll.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-20 07:10:25 -05:00
notify-send "${random_image_file} @ ${random_gravity}"
2024-05-19 18:53:45 -05:00
2024-05-20 07:11:18 -05:00
scrot --overwrite /tmp/currentworkspace.png
2024-05-20 07:10:25 -05:00
#monitorshot.sh /tmp/currentworkspace.png
convert /tmp/currentworkspace.png -blur 0x9 /tmp/currentworkspaceblur.png
composite -gravity ${random_gravity} ${random_image} /tmp/currentworkspaceblur.png /tmp/lockbackground.png
2024-05-20 07:11:18 -05:00
i3lock --tiling -i /tmp/lockbackground.png