Mac OS X script to download hi-res images from various subreddits and store them in a folder for use in random Desktop & Screensaver system preference backgrounds
-
Downloads hi-res* files from a set of sub-reddits. Uses several built in command line tools from Mac OS X Developer tools including: curl, tidy, sips, cut, egrep, cp
-
There is a lot that can be done to clean this up and make it a little more robust and configurable but it should do the job.
Feel free to fork and send pull requests. I just hacked this together out of frustration as I could find no tool to do the exact job.
- Open the Terminal.app
- Change to a directory where you'll store the script.
cd /path/to/project
if it doesn't exist you canmkdir -p /path/to/project
- Clone the repo with
git clone https://github.com/dwstevens/rEarthPornBackgroundr.git
. This will create a directory called rEarthPornBackgroundr in the path you created/changed to in step 2. - Open the rEarthPornBackgroundr.sh script (e.g.,
nano rEarthPornBackgroundr.sh
and modify thedesktopImgDirectory
variable. This should be the directory you specify in the Desktop & Screensaver system preference panel. Save the file, if using nano, control-x will do the job. - After saving the file, you may have to modify the exec flag on the file so that it can be run via a simple
/path/to/project/rEarthPornBackgroundr.sh
otherwise you have to run it with a bash prefix/bin/bash /path/to/project/rEarthPornBackgroundr.sh
which ain't so bad? - Run the file via
./rEarthPornBackgroundr.sh
, which assumes you are still in the directory with that file in it. Otherwise you either need tocd /path/to/project/rEarthPornBackgroundr
or/path/to/project/rEarthPornBackgroundr/rEarthPornBackgroundr.sh
- You will see a bunch of output, and if everything went ok, you'll have a bunch of new images in your designated desktop images folder.