For a selected file in Finder, I like to run a perl script using Services. I created an Automator process that runs an AppleScript:
on run {input, parameters}
tell application "Terminal"
activate
do script "/Users/myaccountname/Applications/TeXcount_3_0/texcount.pl \"" & (input as string) & "\""
end tell
end run
The only problem is that the selected filename appears as something like:
"Macintosh HD:Users:myaccountname:Documents:texfile.tex"
which the perl script cannot understand. How can I make it a UNIX-like filename?