(* $Id: mail-attach.scpt,v 1.3 2006/06/07 21:17:01 jmates Exp $ The author disclaims all copyrights and releases this script into the public domain. Creates message with dropped files as attachments. Save as AppleScript application to use. *) on open names tell application "Mail" -- set body from STDIN if possible? set newMessage to make new outgoing message with properties {content:return & return} -- with properties {subject:theSubject, content:theBody & return & return} -- TODO allow selection of signature/sender address by a command line -- option somehow? set everySignature to every signature tell newMessage set visible to true (* TODO fix this... if (count of everySignature) is greater than 0 then set message signature to signature 1 of everySignature end if *) repeat with i in names tell content make new attachment with properties {file name:i} at after the last paragraph end tell end repeat end tell activate end tell end open