Using Keyboard Maestro to drive Marked 2

My writing tools are varied based on where/how I'm writing - laptop vs iPad vs iPhone. But the final review process almost always ends up on my Mac in Marked 2. Marked 2 is a peculiarly wonderful app in that it doesn't directly create anything. Marked 2 is just for viewing Markdown text files.2 So when I view my content in Marked 2, I can see the content using the same CSS styling as I use on my site.

Normally when I run Marked 2, I will open a folder from Dropbox that holds all of my Markdown (MD) notes. Marked 2 has the ability to open a folder and then change what document it being previewed based on what file has had the most recent revision. This makes my writing time so much more effective because I can make changes to one post, updates notes in another file, come back to a 3rd document - and I don't have to change anything in Marked 2.

Brett Terpstra (@ttscoff), the creator of Marked 2 wrote in a recent blog post about using URL handlers in Marked 2. I looked a while back on using the URL handlers1 and the format is pretty simply. Basically you can open a MD file in Marked 2 from either a link or from Terminal command. For example:

open -g 'x-marked://open?'

The problem I had with the URL handlers in the past was the it required an actual filename. I don't always know the full file name when I open Marked 2 because I want it to open my MD folder, not a specific file. What I wanted out of the URL handler was something equivalent to this:

open -g 'x-marked://open?file=~/Dropbox/MDFolder&raise=true'

Since Marked 2 didn't have the option to open a folder, I looked at creating a macro in Keyboard Maestro. The goal was to create a keyboard short cut to open Marked 2 and have it open my normal MD file folder.

With this macro, Marked 2 is opened and then will open my MD file folder.

  1. Or x-callback-url for iOS reference.  

  2. Brett got a Marked 2 revision kicked back because the Apple reviewer couldn't create a file. RTFM... ;-) 

Previous posts:

  1. Incorporating Location Hierarchy on WO Print

    My company has recently been challenged with how we're using Maximo. On one front we're deploying Maximo to new sites that are transitioning off of another EAM platform. On the other front we have a facility that's tripling the size of the installed asset count. Both sites are dealing with …

  2. Setting PM to 1st Day of the Month

    First off, shout out to Bruno Portaluri (@bportaluri) for this tip. He summarized an answer to a question I had just received a few days earlier from one of my Planners. This Planner asked if we could schedule a PM to come out the first Friday of each month. At …

  3. Maximo's Built In Sharing Service

    One of the challenges in my Maximo environment is an efficient way to keep and store 'living documents'. A lot of us have Dropbox, Box, SharePoint, etc., but most of those services are either restricted from widespread access (Dropbox) or have a versioning system (SharePoint) that can make keeping living …

  4. The Division for Destiny Players (Pt 3)

    First and foremost, The Division is a looter shooter. Your character pewpews the bad guys and the bad guys drop new loot. In previous posts I went over how your loot affects your stats and abilities and how your loot creates a class for your character. These two explanation now …

  5. The Division for Destiny Players (Pt 2)

    One of the big differences between The Division and Destiny is your character in The Division (TD) starts out "classless". In Destiny (D1) your first choice was whether you want to be Titan, Hunter, or Warlock.2 Then as you progressed with your character in D1 you gained talents specific …