Dies funktioniert für mich mit der neuesten Version von Sierra
property posixPathofSelectedFinderItems : {} property QposixPathofSelectedFinderItems : {} -- stores the selected files in the active finder window -- in the variable "these_items" tell application "Finder" set these_items to the selection end tell -- returns the Posix Path of each of those files and -- stores all of that info in the "posixPathofSelectedFinderItems" -- as a list repeat with i from 1 to the count of these_items set this_item to (item i of these_items) as alias set this_info to POSIX path of this_item set end of posixPathofSelectedFinderItems to this_info end repeat repeat with i from 1 to number of items in posixPathofSelectedFinderItems set this_item to item i of posixPathofSelectedFinderItems set this_item to quoted form of this_item set end of QposixPathofSelectedFinderItems to (this_item & " ") end repeat tell application "Terminal" activate do script with command "clamscan --bell -i " & items of QposixPathofSelectedFinderItems end tell set posixPathofSelectedFinderItems to {} set QposixPathofSelectedFinderItems to {}