Mugshot + Automator = Download Color Field Images 1.0

I wanted to start trying to separate my internal Flickr kit from the main Mugshot code-line, and I wanted to play around a bit with Automator, and here’s the result. The action uses the Color Fields group on Flickr and downloads up to 10 images that match the color you type in. To install, download the action, unzip it and place it in ~/Library/Automator or /Library/Automator. In the future, I’ll try to just include them inside the Mugshot application bundle. A couple caveats with this release:

  • This initial version of the action simply tries to find images tagged with the color you enter, which doesn’t guarantee a close match. Most of the basic colors are covered pretty well: orange, yellow, red, blue, green, black, white, brown, purple.
  • The code will attempt to download the full-size version of each image, which may take some time, especially on slower connections, but it doesn’t provide any progress indicator yet. Be patient :) If you want to know more, click the “Log to Console” checkbox - the progress and URLs will show up in the Console.
  • It will download the first ten matches. So, with this version, you’ll likely get the same images every time you type the same color in. I’ll try to randomize it more in the next update.
  • The code does not yet check for license information before downloading. Please respect owner’s licenses.

If you get a chance, check out the Color Fields group - there’s thousands of beautiful photos there. And, the admins have started going through photos and tagging them with actual RGB and HSV data - which opens up the door to make future versions of the Automator action much MUCH smarter. For example, it would be nice to select an actual color from a color wheel, and have the action return the closest matches - very similar to the awesome Colr Pickr by jbum. There’s plenty of room for other improvements as well - allow the user to choose what size to download, provide a progress indicator, allow the user to specify the number of images to download, and randomly choosing from all matches instead of downloading the first 10.

Go download it and give it a try!

I had intended to turn this blog posting into a list of tips and tricks of the things I ran into, but the documentation was pretty thorough and I ran into only minor hitches. I had a couple small questions about the AMPathPopupButton class that the documentation recommends - and I posted it to the automator-dev list here. Besides those, the only recommendation I have is to be careful about updates to your Info.plist file - Xcode didn’t always pick them up during a build, but if I first cleaned the target, the new info would get picked up.

Update: I removed links to version 1.0 of the action. Please see this post for version 1.1.

0 Responses to “Mugshot + Automator = Download Color Field Images 1.0”


  1. No Comments

Leave a Reply