I have a macro that, in part, opens a new Chrome window and then a bunch of new tabs within that window. I use this macro weekly. But Chrome is slow and a resource hog. I'm wondering if Safari would be better for this task, but I don't want to manually recreate all the actions and copy and paste the URLs.
Is there a way to convert Chrome actions to Safari actions?

@hello has showed you a way to do this using the KM Editor UI.
Another approach is to edit the XML of the Chrome Actions.
Several ways to do this, but here is perhaps the simplest:
- Export the Macro with the Chrome Actions to a
.kmmacros
file
- Edit this file
- Find:
<key>WebBrowser</key>\n\t\t\t\t\t\t<string>Google Chrome</string>
- Replace with:
<key>WebBrowser</key>\n\t\t\t\t\t\t<string>Safari</string>
- Import this revised file into KM Editor
My preference is to use BBEdit to make this edit, using its excellent Find
tool to find and replace all.
For reference here is the XML of the same Action, with the first using "Google Chrome" and the second using "Safari":
Google Chrome
<dict>
<key>Argument</key>
<string>https://chrome.com</string>
<key>Command</key>
<string>NewTab</string>
<key>MacroActionType</key>
<string>SafariControl</string>
<key>TimeOutAbortsMacro</key>
<true/>
<key>WebBrowser</key>
<string>Google Chrome</string>
</dict>
Safari
<dict>
<key>Argument</key>
<string>https://safari.com</string>
<key>Command</key>
<string>NewTab</string>
<key>MacroActionType</key>
<string>SafariControl</string>
<key>TimeOutAbortsMacro</key>
<true/>
<key>WebBrowser</key>
<string>Safari</string>
</dict>
One final note: Instead of changing to "Safari", you might change to "Front Browser" to make your Macro more flexible. If need be, you could open the Browser of choice at the top of your Macro.
Questions?
Thank you. That's the kind of solution I was looking for, though the manual suggestion by @hello works for a few actions here and there.
I'm a huge fan of BBEdit, as well. Great Find tools.
1 Like