So my job is moving, and while I’m not 100% sure I’ll be moving with it, I do want to explore my options, which include finding possible apartments until I decide.
My workflow looks like this:
Use saved search in local (Norwegian) apartment hunting website
Look at apartment
If I like the apartment, copy the address
go to Google Maps
Paste apartment address
Select the directions button
type Work [1]
Usually just wait for it to load, but sometimes I do need to select the public transport option in case I was doing something else on google maps before this
I do this perhaps ten times per session, several sessions per week, so I thought I’d try to automate it.
I suspect I could make a javascript bookmarklet which gets the address from the CSS on the apt hunting site and automatically search google, but seeing as I’m not very good with javascript, that very quickly ended up being plan B, if not C.
First I tried with Keyboard Maestro, which I haven’t actually used before. I ended up searching for the direction between “Wait For Safari to FiniWork” to “Your loca”, but like – really quickly.
I futzed about for half an hour trying to make this work, but I’d like to hear if I’m barking up the wrong tree. Is there an obvious solution I’m missing?
[1]: Since I can’t have two addresses in the clipboard at the same time, I “moved” my work address for this. I’m using Alfred, so obviously I could have tons of address in the clipboard history and switch between them, but that adds complexity when automating.
One option would be to use a scriptable browser like Fake.app . But given that you have Alfred, I’d create a workflow with a trigger passing the current selection as argument, and pipe it to a script to open a customized Google Maps directions URL.
Sadly, VBA in Excel for macOS is lacking some stuff…I did an VBA thing on Excel for Windows that implemented a “lookup distance” function. Nice if you have a list of addresses…no idea how to get it working on Excel for macOS.