View Full Version : AppleScript question
Jul 13, 2006, 01:31 PM
Not sure exactly where this would be better posted but a mod can move it if they think it should go elsewhere. I'm new to AppleScript and am trying to do something I did on Windows. I'd like to be able to copy a directory (in this case on a thumb drive called THUMB DRIVE in /SAP/PortableThunderbird/Profiles/Mail to /Documents/Mail on the startup drive) when the thumb drive is connected. Because I use Thunderbird where I go for my job and such, I like to be able to keep all the inboxes and such synced. Any help would be greatly appreciated. :D
Jul 13, 2006, 10:43 PM
How did you do it in windows
(sorry I cant help you with the apple script problem :( )
Jul 14, 2006, 04:32 AM
do shell script("cp /SAP/PortableThunderbird/Profiles/Mail/* /Documents/Mail")
should do it, I'm assuming that you have a documents folder on the root of your drive (not the one in your home folder) if it's in your home folder it is
do shell script("cp /SAP/PortableThunderbird/Profiles/Mail/* ~/Documents/Mail")
both the above assume the Mail folder exists in the documents folder.
If the folder is in the thumb drive you need to add /Volumes/THUMB\ DRIVE (the backslash is to cancel out the space) to the beginning of the /SAP/Portable... bit.