Scripts for specific workspaces

On episode 439 of MPU (beginning at 26:39 in the podcast), @MacSparky mentioned a script where he would type “;rmpu” and it would open up all of the programs he uses to record an episode.

Is there a place where I can go to find a tutorial on how to set something like this up? I love the idea of this and would like to customize my own workflow to open specific apps for certain scenarios.

I assume he’s using a program like Keyboard Maestro for this?

Forgive me if this has already been covered in here. But the information I’m finding is more general than specific. Thanks in advance!

1 Like

I’m not sure if it’s how David is doing it, but it is simple in Keyboard Maestro. Your “trigger” is the “;rmpu” typed string, and then there is an “Activate Specific Application” action. Just add one of those for each application you want. You could also add actions to quit any app you don’t want running.

Edit:
Here’s what it might look like (obviously, with the apps being different):

53%20AM

1 Like

What @Evan said.

And at each application ‘step’, you can add the “Manipulate a Window” action, that will allow you to specify where you want that application’s window opened, and in what size.

Included would be options to resize, move to, move and resize, centre at etc.
And the resize can be in positions similar to what most window managers would offer (Left Column/Top Half/Top Left etc.), or a Custom size.

So you string together the apps you want opened, and where/how you want their windows to appear, and trigger it with the keyphrase.

Hope that helps!

1 Like

Alternatively you can do it in Alfred with a workflow with an Open Files action & a call to a scriptable window manager (I use Moom).

I created a very simple Keyboard Maestro macro that lets me trigger a macro by simply typing its name. I created a global keyboard shortcut ( ⌥⇧⌘K) to activate this macro.

Keyboard%20Maestro%20-%20Trigger%20Macro%20By%20Name

As an example, if I wanted to trigger a macro to dismount one of my hard drives, I could ⌥⇧⌘K and start typing to find the macro I’m looking for.

Keyboard%20Maestro%20-%20Trigger%20Macro%20By%20Name%20-%20Example

2 Likes

I actually do this using Keyboard Maestro. I’m on the road now, iPad only, but I’ll do a post and share thes scripts when I get back home this week.

6 Likes

Incredible! Thank you!

1 Like

This is interesting; I have setup a Keyboard Maestro macro for that, which works fine if you open app and leave them as they are, but I ran into problems when trying to open new desktops, distribute apps on different desktops and put them at a specific position on the screen.
It seems that you have to pause the flow of the macro once in a while and wait until the screen has been set up before progressing with the macro.

I won’t go into all the deets, unless you’re interested, but I actually did something very similar to this using just Automator & Launchbar. Perhaps not as sophisticated or powerful, but gets the job done.

1 Like