Keyboard Maestro Pause Condition — BBEdit Footnotes

Keyboard Maestro 5 contains several new conditional actions. The "Pause Until Conditions Met" actions is modest sounding but contains a lot of power. Fundamentally, the action will pause the currently running macro and watch for a specific condition to be met. What condition? Well, pretty much anything.

 

Wait For Menu

I'm sure there are some very interesting ways to use this, but here's a somewhat boring yet powerful macro for entering a footnote in Markdown on BBEdit.

Footnote Macro

 

When the macro is triggered, it asks for a footnote title then sets a BBEdit Jump Mark. After jumping to the bottom of the page and inserting a footnote placeholder, the macro waits. It waits for me to finish typing my footnote. When I hit return, the macro continues where it left off and executes the BBEdit "Jump Back" function which places my cursor right back where it was. Then the footnote link is inserted and I can continue typing.

To be clear, other Keyboard Maestro macros can still be run while the first macro is paused and waiting to continue. The Pause action is not pausing KM but rather just pausing the single macro. I don't think I would let a macro sit paused for days, but certainly for normal use I have not seen any problems.