Monday, November 28, 2011

Setting multiple wallpapers on Ubuntu 11.10

Galleria isn't working right now. It uses gconf whereas Gnome 3 is on dconf. Ubuntu 11.10 is on some weird hybrid of both as far as I can tell. Since I used Quickly to develop galleria, and that's still generating code that doesn't work with the way we're supposed to use dconf (dynamic binding) things are kinda in limbo at the moment.

So I whipped up a script to do the job instead. Just replace the source path with the full path to your folder containing the wallpapers you want to set (it's near the bottom).

src = '/home/ubuntu/Pictures'
imgfiles = glob(os.path.join(src, '*'))
wp = [img for img in imgfiles if is_image(img)]

Then run the script from terminal.

~$ python

This doesn't work on older Gnome 2 desktops though. The script is available for download from MediaFire, for anybody interested.