Subroutine to Get List of All Macros and IDs in a Specific Macro Group

A KM user recently asked about getting a list of all the macros in a specific macro group in order to create a pick list to simplify choosing one macro out of the many they had in their KM environment. As it happens, the solution to their request was already built into KM but I had the thought that generating such a list might be useful in other use-cases. so I created this KM subroutine to do just that.

[SUB] Get List of All Macros and IDs in Specific Group

Inputs:
Local__Macro_Group: The name of a KM Macro Group
Local__Delimiter: separator between each UUID and macro name - by default ","

Output:
A list of the UUIDs and names of every macro in the specified Macro Group in the form:
<UUID><Delimiter><name>
<UUID><Delimiter><name>
etc.

Here's the subroutine:

Download Macro(s): [SUB] Get List of All Macros and IDs in Specific Group.kmmacros (6.4 KB)

Macro-Image

Keyboard Maestro Export

Macro-Notes
  • Macros are always disabled when imported into the Keyboard Maestro Editor.
    • The user must ensure the macro is enabled.
    • The user must also ensure the macro's parent macro-group is enabled.
System Information
  • macOS 13.6.1
  • Keyboard Maestro v11.0.2

And here is a simple macro that tests the use of the subroutine on the global macro group, uses the generated list in a Prompt for the user to choose and then runs the selected macro:

Download Macro(s): Test [SUB] Get List of All Macros and IDs in Specific Group.kmmacros (3.5 KB)

Macro-Image

Keyboard Maestro Export

Macro-Notes
  • Macros are always disabled when imported into the Keyboard Maestro Editor.
    • The user must ensure the macro is enabled.
    • The user must also ensure the macro's parent macro-group is enabled.
System Information
  • macOS 13.6.1
  • Keyboard Maestro v11.0.2
3 Likes

Hello Taj (@tiffle)

Thanks for sharing this useful Subroutine…

It makes it so much easier now getting all Macros of a specific group…

another thing I don’t have to build on my own - again many many thanks :pray:

Greetings from Germany

Tobias

1 Like

You're welcome Tobias - hope all's well :grinning:

1 Like

Yeah, not all but it gets better from day to day … let’s say I am happy to be back in the game after months of all kind of trouble, hassle and not being able doing things I love to …

Greetings from Germany

Tobias

1 Like