Created
June 22, 2016 13:03
-
-
Save edmondscommerce/279558ce230442aa251526141dd7a4c8 to your computer and use it in GitHub Desktop.
Bash script to change wallpaper on Fedora - Ideal to be run on a cron basis
This file contains hidden or 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
#!/usr/bin/env bash | |
PID=$(pgrep -n gnome-session) | |
export DBUS_SESSION_BUS_ADDRESS=$(grep -z DBUS_SESSION_BUS_ADDRESS /proc/$PID/environ|cut -d= -f2-) | |
GSETTINGS_BACKEND=dconf | |
gsettings set org.gnome.desktop.background picture-uri '"file://'$(ls ~/Pictures/Wallpapers/*.jpg | shuf -n 1)'"' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment