ngwallpaper is a tiny Python script useful to programmatically download and decorate your OSX desktop with randomly selected wallpapers provided by National Geographic. Supported repositories are:
- NGM latest wallpapers.
- NGM archived wallpapers.
- Miscellaneous galleries: 'Life in Color' (i.e. 'kaleidoscope', 'red', 'orange', etc.), 'Visions of Earth', 'Bird Wallpapers', 'Underwater Wreckage', 'Patterns in Nature' (i.e. 'flora', 'reflections', etc.), etc.
I created this script for my own personal use. It should work in older OSX versions, and it should be easily extended to support other platforms, multi-screen configurations, etc. Anyway, I haven't tested this in other platforms / configurations, and I don't plan to do that in the future :)
Clone this repository somewhere in your computer.
$ cd ~ $ git clone https://github.com/carlosabalde/ngwallpaper.git
Install the Python libraries required by the script.
$ sudo pip-2.7 install BeautifulSoup
Manually execute the script for the first time.
$ python2.7 ~/ngwallpaper/ngwallpaper.py --use-ngm-latest --use-ngm-archive --use-miscellaneous-galleries --destination ~/Pictures/ngwallpapers/ --store --retries 100
This should change the background of your desktop and create a couple of files in
~/Pictures/ngwallpapers/: the wallpaper image and a text file containing some information about the image.
Add a new entry to your personal crontab (
crontab -e) to periodically change your wallpaper.
0 * * * * /opt/local/bin/python2.7 ~/ngwallpaper/ngwallpaper.py --use-ngm-latest --use-ngm-archive --use-miscellaneous-galleries --destination ~/Pictures/ngwallpapers/ --store --retries 100 > /dev/null
When using the
--store, previously downloaded wallpapers are not removed. You may want to use the folder containing all those images as a source for your screen saver.