AppleScript - CopyPath.app

CopyPath.app


tellapplication"Finder"

setseltotheselection

if(countofsel)isgreater than1then

settheListto""

repeatwitheinsel

settheListtotheList&POSIX pathof(eastext) &return

endrepeat

set the clipboard totheList

elseif(countofsel)isequal to1then

set the clipboard toPOSIX pathof(selastext)

else

set the clipboard toPOSIX pathof(targetofwindow1asalias)

endif

endtell

推荐阅读更多精彩内容