Peter - What do you call the XML snippet that represents an Action?

Peter - A while ago you showed me how to invoke KM from AppleScript to execute an action, using the portion of XML between the "dict" nodes, like this:

What do you call this XML text? Do you call it a snippet, or what? The reason I ask is I want to post an example macro that will do this, and I need a good name for it. "Execute a Macro Snippet"? "Execute Macro Code" sounds confusing, almost like you're executing a UUID.

Thanks.

I think “Execute Action Script” makes the most sense.

The XML is simply the XML export form of the action.

It is not guaranteed to stay unchanged forever. It should generally be ok to use in future versions for some period of time, since the loader will have to be able to update it, but eventually after several major versions then changes may be sufficient that the loader can no longer load the old XML (this is why I advise people to upgrade one major version at a time, even if upgrading from an old version, run each major version at least once).

And it is possible one day I will move entirely away from XML, perhaps to sqlite or perhaps to something else entirely.

1 Like

Yeah, that makes sense - you shouldn’t be stuck trying to maintain backwards compatibility to things like this.

As long as you still have the import/export to XML feature, it’s cool if you want to change formats. But please don’t ever take that away. I’ve used it to make global changes to my naming standards, as well as other things, and it would suck to not have that. :slight_smile: