Feedback and criticism are welcome. And ideas for new filters are welcome.
Here's a big new macro that allows you to combine dozens of different filter actions into a single action. Many of the filters are built-in Keyboard Maestro filters found in the Filter Action, but many of them go beyond that by accessing or creating popular shell filters that Keyboard Maestro does not directly support. Here's a simple example to illustrate what this macro can do.
The result placed into the FilterResult variable is:
1 Abc 2 Def 3 Ghijk 4 Lmn 5 Op 6 Qrstuvwxyz
But there are many more filters. Here's the current list. More will be added in the future. You can add your own filters, but I recommend that you make requests for filters and I will add them, so that consistency of format and naming are maintained.
- Merge Lines
- Split Every Argument
- Remove All Strings
- Quote Every Line
- Smart Quotes
- Dumb Quotes
- Sort Lines
- Reverse Line Order
- Reverse Character Order
- Shuffle Lines
- Trim White Space
- Remove Blank Lines
- Keep First N Lines
- Delete First N Lines
- Keep Last N Lines
- Delete Last N Lines
- Capitalize
- Uppercase
- Lowercase
- Unix Line Endings
- Windows Line Endings
- Mac Line Endings
- Keep Column N
- Minimum Length N
- Maximum Length N
- Number Lines
- Squish Lines
- Fold Lines
- Char=X
- String=XXX
- Search=XXX
- Separator=X
- Number=NNN
(The last five commands are pseudo filters that simply set variables for use in other filters.)
Filter Utility v1.0 Macro (v11.0.3)
Filter Utility v1.0.kmmacros (70 KB)