Copy Message URLs AppleScript for Apple Mail
Mac OS X — 4 Dec 2007 15:36 — 1625 days ago

In a previous post I noted the usefulness of the message URI scheme (although I wonder why Apple didn’t use the existing mid scheme).

I wrote an AppleScript to copy the message URIs of all currently selected messages in Apple Mail to the clipboard:

tell application "Mail" if selection = {} then return set urls to {} repeat with msg in selection as list set end of urls to "message:%3c" & (message id of msg as string) & "%3e" end repeat set AppleScript's text item delimiters to ", " set the clipboard to urls as string end tell

I stored this as an .scpt File into my ~/Library/Scripts/Applications/Mail folder so I can access it from the AppleScript menu in Mail.

Update: John Gruber also has an article with a bit more research about this feature today, at Daring Fireball.


Powered By blojsom