ashinkarov/i3-extras — pull request #3 by dagon666 (2014-02-01 10:22:06+00:00)
Title: Added script to randomly select a wallpaper from given directory

Added a script which sets a random wallpaper from the set of images in a directory. I find this script very useful I launch it once during the i3 startup by adding:

exec --no-startup-id

in the i3 config. When launching i3 it sets a random image as a desktop background. It uses feh in order to change the background.

In order to configure a custom directory with images the script must be edited. This line must be changed:

29	# wallpaper basepath
30	# modify this path up to your preferences
31	my $g_base= $ENV{'HOME'} . "/Pictures/wallpapers";

By default it looks for images in ~/Pictures/wallpapers.