Hemanth's Scribes

web

How to Use the Real-time Earth Wallpaper Script for Linux

Author Photo

Hemanth HM

Thumbnail

How to Use the Real-time Earth Wallpaper Script for Linux

How to use the real-time Earth wallpaper script for Linux

1.Save code part to a file, say change.sh while [ 1 ]; do COUNTER=0 while [ $COUNTER -lt 60 ]; do wget http://www.opentopia.com/images/cams/world_sunlight_map_rectangular.jpg -O world.jpg temp=$(stat -c%s world.jpg) if [[ $temp > 1000 ]] then rm world_sunlight_Wallpaper.jpg mv world.jpg world_sunlight_Wallpaper.jpg break fi sleep 5 let COUNTER=COUNTER+1 done sleep 3600 done 2. Create a new folder in your home partition, say wall. 3. Set permissions and run : $ cd ~/wall $ cd chmod 777 change.sh $ ./change.sh 4.Set the image as wallpaper : gconftool-2 --type string --set /desktop/gnome/background/picture_filename ~/.gnome2/world_sunlight_Wallpaper.jpg 5.Put script to start up : $ mv /path/to/change.sh /etc/init.d/ $ update-rc.d change.sh defaults

Now the scripts updates the wallpaper for every “3600 seconds” and can be changed as per your wish in the script.

#javascript#linux
Author Photo

About Hemanth HM

Hemanth HM is a Sr. Machine Learning Manager at PayPal, Google Developer Expert, TC39 delegate, FOSS advocate, and community leader with a passion for programming, AI, and open-source contributions.