I'm trying to save the output of a command in a variable, i.e:
Run Shell Script
Set Value of Variable
This has suddenly stopped working because the output from the shell script is no longer plain text:
( "<NSAppleEventDescripto [ 'utxt'(\"M:/titles/synonyms/PDFs/correx-2011-11-18\") ]>"
I don't understand why this is, since other shell scripts are still working fine. How to I make the shell script return plain text as it used to? Or, how do I make it into plain text so it can be saved in "Set Value of Variable"?
I guess an alternative solution might be to use AppleScript to run the shell command, though that doesn't solve the original problem.
How to recreate in Automator: 1. Get Specified Text: "M:/titles/synonyms/PDFs/correx-2011-11-18" 2. Set Value of Variable: create a new variable. 3. Run Shell Script: "sed -Ee 's/.:(.*)/\1/g' | sed -Ee 's/\///g'" to /bin/bash, stdin
When you run Automator, the results of the shell command MAY be in the NSAppleEventDescripto format. If they are, disabling "Set Value of Variable", running, then renabling and running again seems to fix it.