Importing Mail with MailTags

I was reading the book Take Control of DEVONthink and read:

Note: If you use MailTags (part of the MailSuite plugin for Apple Mail), tags you applied to messages using MailTags are imported, along with the messages, as DEVONthink tags. See Tag Documents for more on tags.

I haven’t upgraded to Sonoma yet because I have been trying to determine the best way to maintain the tags I have assigned. However, when I tried importing mail with MailTags tags, they were not converted to DEVONthink tags. I used the import mail feature from within DEVONthink itself.

I am also trying to get the DEVONthink Mail Plug-in working. However, when I use the Add to DEVONthink 3 menu option in Mail, nothing happens.

Any ideas?

So, I think I know what is happening, but I am not certain how to fix it.

The message I have selected while using the Add to DEVONthink 3 menu option from Mail was previously imported into the DEVONthink DB with DEVONthink’s import feature. However, even if I delete that message from DEVONthink and Empty the DEVONthink trash, Add to DEVONthink 3 still does nothing.

Any ideas?

It does appear that MailTags tags are only imported into DEVONthink if the import is initiated from the Mail application.

When using Add to DEVONthink 3, is it possible to specify a destination Group?

Via the Mail application or via the Sidebar > Import > Email interface. An installed & enabled Mail plugin and also an installed MailTags plugin are required, therefore this won’t work via AppleScript and not on Sonoma.

See Preferences > Files > Import > Destination

I have not upgraded to Sonoma yet. I am still running 13.6 (22G120). I am still working on figuring out how to maintain the tags I have set with MailTags. DEVONthink may be a good solution.

However, I have run into a problem where I cannot import messages from Mail and maintain my tags set with MailTags.

I do have the Plugin enabled.

If I select a message and do Add to DEVONthink 3, it will be sent to DEVONthink successfully. There is an exception. Before I used Add to DEVONthink 3 from the Mail application, I tried the DEVONthink import functionality.


I imported many, but not all, Mail messages this way. I thought this would maintain the tags set with MailTags, but it did not. I deleted those messages and emptied the DEVONthink Trash. However, selecting one of those messages and using Add to DEVONthink 3 from the Mail application does nothing.

DEVONthink must be storing a hash or some other identifying material and is refusing to import the message again because it believes there is already a duplicate message. It did not clear this hash when I deleted the message and emptied the DEVONthink trash.

Now, I could probably just start over with a fresh database, but I would rather not do that at this point. I am hoping there is a workaround for this bug.

Any ideas?

Thanks for the pointer to the preference.

Did you try searching for the message that does not get imported in DT? DT uses the message ID as UUID in its database, and therefore you can’t import the same message twice. But in my experience, a message that is completely gone from DT can be imported again.

I’m just going to mark this one up as me being blind. I could have sworn I saw a problem here, but cannot reproduce anything. It seems to be working without issue.