Email Archiver - Using the output in DT

Email Archiver is a fantastic little tool that takes the contents of an Outlook or Apple mail folder and converts the emails into pdfs with the attachments in an associated directory.

If you want to archive emails or analyse their contents, it is superior to DT’s native email handling (which doesn’t index attachments for example)

Email Archiver produces a complex hierarchy of directories that look something like this this:

----2013-12-12 05.34.46Z Record of conversation (attachments) [a directory with attachments]
------attachment 1.pdf
------attachment 2.xls
----2013-12-12 05.34.46Z Record of conversation [the email itself in pdf format]

This directory structure is easily imported into DT, but it can still be tedious to find a particular email or to organise and tag.

The little script attached to this post will take all the emails in the directory structure and make them look this:

----2013-12-12 05.34.46Z Record of conversation (attachments) [creation date:2013-12-12 05.34.46]
------attachment 1.pdf [creation date:2013-12-12 05.34.46 tag:att]
------attachment 2.xls [creation date:2013-12-12 05.34.46 tag:att]
----Email from Fred Smith to J Khumalo [creation date:2013-12-12 05.34.46 tag:eml]

The URL link of each email will link to a tag group containing all the attachments for that email. The subject of each email is placed in the spotlight comment field

The ‘att’ tag will show all the attachments, and the ‘eml’ tag all the emails. A smart group to show results from both tags will show all emails and attachments in chronological order (if sorted by creation date).


  1. Install Smile (its needed for the regular expression support it adds to applescript)
  2. Unzip and drop the attached script into the DT scripts directory

a) Make sure you are in split view. (This shows directories and files in the same view)
b) Click on the ‘name’ column, of the list view, so that the emails are sorted by name
Select every directory and email produced by Email Archiver you want to convert. This will involve opening every sub directory so every single item is highlighted.
c) Run the script.

make sure you have backups!
The conversion of From and to addresses isn’t always perfect. The regexp still needs some work.

convert email archiver (10.6 KB)