What I want to do
I want to create a simple Automator service that:
- Takes
text
as input fromany application
, - Does some logic on given input
- Replaces the selected input text with the calculated output
The problem
The return
value in the JS script does not replace the selected input text. I have no clue why. Does anyone have experience with this?
I am running macOS Sierra 10.12, using Automator 2.7
Best Answer
The problem was related to the macOS version. After updating to
10.12.1
the text is now being correctly replaced!Edit: for those interested in the alphabetic sorting, simply add a
Run Shell Script
block and fill insort -f
, like so: