gnome desktop background changer

Michael Haney thezorch at
Sat Oct 16 15:38:05 UTC 2010

On 10/16/2010 05:01 AM, Jacob Mansfield wrote:
> I am attempting to make the desktop background in gnome change 
> automatically to a random image from a set folder. I know the command 
> I need is
> gconftool-2 --type=string -s 
> /desktop/gnome/background/picture_filename /full/path/to/image/file
> I have worked this into a basic shell script:
> time=$1
> # time to wait between changing the background in secs
> while [ : ]
>  do
>  for filepath in `cat list`
>  # list is a list of all files in the backgrounds directory and is the 
> only other non-image file in the folder
>   do
>   echo $filepath
>   # for debug
>   gconftool-2 --type=string -s 
> /desktop/gnome/background/picture_filename “$filepath”
>   sleep $time
>   done
>  done
> however allthough this sets the value (I can see it in the xml 
> configuration file with emacs) the background simply goes to the set 
> colour not the image. is there another value I need to get the 
> background as an image? or is there something wrong with my script? 
> all help appreciated.
> Jacob Mansfield
> Programmer
I usually use Wally to do this.

More information about the ubuntu-users mailing list