use pywal if installed

This commit is contained in:
Luke Smith 2020-02-09 09:24:13 -05:00
parent d8c4fbd0e9
commit 4acbbc07d3
No known key found for this signature in database
GPG key ID: 4C50B54A911F6252

View file

@ -3,7 +3,15 @@
# In LARBS, ~/.config/wall.png is the location of the system wallpaper. This # In LARBS, ~/.config/wall.png is the location of the system wallpaper. This
# script, if given an argument, moves it there. This script without an # script, if given an argument, moves it there. This script without an
# argument sets ~/.config/wall.png as the wallpaper, which is required on login # argument sets ~/.config/wall.png as the wallpaper, which is required on login
# if you don't want a blakc screen. # if you don't want a black screen.
[ ! -z "$1" ] && cp "$1" ~/.config/wall.png && notify-send -i "$HOME/.config/wall.png" "Wallpaper changed." [ ! -z "$1" ] && cp "$1" ~/.config/wall.png && notify-send -i "$HOME/.config/wall.png" "Wallpaper changed."
# If pywal is installed, use it.
type wal >/dev/null && { wal -c ;
wal -s -i ~/.config/wall.png -o ~/.config/wal/postrun;
xsetroot -name "fsignal:xrdb";
killall dwmblocks;
setsid dwmblocks >/dev/null 2>&1 & }
xwallpaper --zoom ~/.config/wall.png xwallpaper --zoom ~/.config/wall.png