Execute Shell Action as a Text Filter

whatsnew
km8

#1

A small change in Keyboard Maestro 8 adds the ability to send text to the Execute a Shell Script action as STDIN.

Since the output of the script can be sent the clipboard, typed in, displayed or saved in a variable, this little change means you can use any unix script as a text filter, to translate text from one format to another.

This could be as simple as using tr a-z A-Z to uppercase text (though obviously you’d use the Uppercase Filter action for that), to far more complex and interesting scripts (such as converting markdown to HTML for example).

Previously, you could write the text to a file, and then adjust the script to read the input from that file, so it’s not so much that this is an entirely new capability, as that it makes this sort of thing much easier and clearer.

Basically, this means any shell pipe sequence can now easily be used to translate text in Keyboard Maestro.


Reverse words order of clipboard