Bradley Giesbrecht
2012-Jun-17 15:19 UTC
[Dovecot] doveadm fetch LARGE attachments and remove message
Looking at the wiki and man pages I am unsure how to fetch email attachments from a unix shell. I have an "doveadm search" that returns the messages that have the attachments I am after. Would I loop through an "doveadm fetch" and use a commandline imap client to save the attachments and move the message to the Trash? Or is there a doveadm command for this? Regards, Bradley Giesbrecht (pixilla)
Timo Sirainen
2012-Jun-18 13:49 UTC
[Dovecot] doveadm fetch LARGE attachments and remove message
On 17.6.2012, at 18.19, Bradley Giesbrecht wrote:> Looking at the wiki and man pages I am unsure how to fetch email attachments from a unix shell. > > I have an "doveadm search" that returns the messages that have the attachments I am after. > > Would I loop through an "doveadm fetch" and use a commandline imap client to save the attachments and move the message to the Trash? > > Or is there a doveadm command for this?No, there's currently no easy way to do this. doveadm fetch doesn't support that. You could possibly do this via IMAP, but it would be difficult to know which MIME part to fetch. Actually it's not even obvious if a MIME part is an attachment or not..