Halfway down the rathole

I had a brilliant idea after writing last night’s post – what if I could automatically kick off the Google Reverse Image Search after taking a screenshot, but only if I was doing it from Lightroom or Photos?

I was pretty sure I had the right tools:

  • Hazel to watch the desktop and “do something” if a file with the right name was added
  • Keyboard Maestro to be the “something” Hazel would activate; it can check to see if the current application is one whose screen shots I care about
  • and I’d already written the Shortcut to search Google, so I could call it from Keyboard Maestro.

It seemed simple, but I spent a couple of hours trying to figure out why the Shortcut saw the name of the screen shot, but the script inside the Shortcut got the name of a temporary file whose contents was the name of the screen shot.

And then I realized that that was a problem I didn’t have to solve – I could just call the script directly from Keyboard Maestro and avoid the trip through Shortcuts.

And that worked right away. I’m saving time and effort every time I need to do the image search – I might never save as much time as I wasted trying to debug my problem, but that’s a different issue, right?

I even used the new technique on a photo I took on our morning walk today – I present a California Scrub Jay. I think.