Given a UUID for a macro group (or smart group), is there a way to get the group name?
For macros, I see MacroNameForUUID, but there doesn't seem to be a corresponding token for macro groups (and smart groups) names. Is there another method to get the name?
I'm am able to generate a list of group and smart group UUIDs using this:
tell application "Keyboard Maestro"
set GroupList to id of every macro group
set SmartList to id of every smart group
end tell
set combList to GroupList & SmartList as list
set text item delimiters to linefeed
return combList as text
And I can get a list of the names using this:
tell application "Keyboard Maestro"
set GroupList to name of every macro group
set SmartList to name of every smart group
end tell
set combList to GroupList & SmartList as list
set text item delimiters to linefeed
return combList as text
But I suspect one can't assume these two lists are in the same order.
Very nice! I don't often need UUIDs since most of the time I enable/disable macros and groups via the native KM action. But there are times when I want to do that from within an AppleScript and having a quick way to look them all up can be very handy for that. Thanks for building this and sharing!
I saw and tried that. My screw up was I somehow missed the Process Tokens action. My eyes skipped right over that detail.
Glad I could provide the inspiration. I missed the Process Tokens action in the Wiki, but not in your example. Thanks for taking the time to share the macro.
LOL. I missed the Process Tokens part too at first - I was trying all different combos of % signs with the UUID token before I decided maybe I should read the whole Wiki page.