It is the updated variant of my copy path
script for Automator
on run {input, parameters}
set res to ""
if not input = "" then
repeat with theFile in input
if not res = "" then
set res to res & return
end if
set part to POSIX path of theFile
set res to res & part
end repeat
end if
if not res = "" then
set the clipboard to res
end if
return res
end run
This script can be easily used as a service