Feature Request: Only Run on This Mac

I have 4 Macs that are running a synced KM file. There are certain macros that I only want to run on specific machines. Currently, if I have a group that I only want to run on 1 Mac I have to:

• Set up a folder and label clearly, e.g 'Timed macros - Study'
• On all other macs, I then have to set 'Disabled on this Mac'

It would be great if I could simply set the opposite of this - Run only on this Mac - on the folder and it then syncs to other macs (but disabled). Setting 'Run only on this Mac' on another Mac would then switch to that Mac.

This would seem to be a simple one to implement, and would be REALLY helpful.

It would also be helpful to be able to set similar options at a Macro level, not just on the folder.

It's not what you're asking for, but in case it's of use and you didn't already know:

"... the %MacUUID% token is a unique ID for each Mac, and can be used to test which Mac the macro is running on"
manual:Macro Syncing [Keyboard Maestro Wiki]

Update: I have just seen this relevant discussion: How to make “disabled on this Mac” default to ON for a particular group?


The suggestion @kevinb provided is the one I use. For instance, in the screenshot below I have three actions.

The top action is a switch action, that uses the token he mentioned. I have each of my machine’s UUID saved to global variables prepended with DND__ (my naming convention for variables I never want to delete), and in the action I use that variable to determine which machine the macro is being executed on and proceed accordingly.

The second action is an assertion action that uses the same token and variable to determine if the machine is my iMac, and if it isn’t, cancels the macro.

The third action is the same as the second, but for the MacBook.

Actions Screenshot (click to expand/collapse)


This can work! I can wrap the actions I need in this, but I still think an off-the-shelf 'run only on this Mac' would be handy.

This is an off-topic suggestion, but whenever asking someone to do something, I would recommend against saying how easy it would be. It diminishes the value of the request, and for software explicitly, it is never as easy as one might hope on first appearance.

For example in this case, you set up your macro group and mark is "only enabled on this Mac". What happens when you go to your other Mac and set the same group to "only enabled on this Mac"?

Anyway, it seems you have some solutions so I don't have to try to puzzle through how this might be implemented in a way that doesn't rapidly become confusing.


I did wince there. :laughing:

1 Like

Fair enough. Although I did qualify it with “It would seem…”. I know there might well be hidden complexities. Will make sure I don't do that again.

Don't mind me at all, I did notice a classic %TriggerValue% for any software developer but was just making light of it. :wink: