Created
July 20, 2015 01:45
-
-
Save pandada8/2dc1c969ed9256f44ec5 to your computer and use it in GitHub Desktop.
wallpaper
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
shopt -s nullglob | |
cd ~/Wallpaper | |
while true; do | |
files=() | |
for i in *.jpg *.png; do | |
[[ -f $i ]] && files+=("$i") | |
done | |
range=${#files[@]} | |
((range)) && feh --bg-scale "${files[RANDOM % range]}" | |
sleep 5m | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment