1
我想測試,如果從文件夾路徑上的一個文件,在不同的文件夾使用該腳本存在:AppleScript的 - 如果文件在文件夾中不重複
set middfilesECON211 to ("/Volumes/middfiles/Classes/Spring14/ECON0211B/HANDOUTS" as POSIX file)
set gDriveECON211 to ("/Users/paolob/Google Drive/Spring 2014/ECON 211/Handouts" as POSIX file)
tell application "Finder"
set foo to every file of folder middfilesECON211
repeat with i from 1 to (length of foo)
if not (exists (item i of foo) is in files of folder gDriveECON211) then
duplicate (item i of foo) to gDriveECON211
end if
end repeat
end tell
我已經試過了一堆if not (exists) ...
條款的變化,但無濟於事。
任何幫助將不勝感激。謝謝!
http://stackoverflow.com/search?q=[applescript]duplicate+files – 2014-02-25 08:51:16