Filter mails upon import

Issue #913 resolved
Tom Jones created an issue

After having piler up and running, it is time to import older .pst and .eml-files. Pilerimport and readpst seem to do a fine job, but I would like to omit importing outdated emails, as it is not longer necessary to keep them.

As far as I can see, neither pilerimport nor readpst provide any parameters to do some filtering. My next idea was to create an archiving rule that rejects emails older than the specified date. Unfortunately there are no date rules that could be created.

Using pilerpurge also doesn't seem to be of use in this case as piler creates a timestamp when importing a mail that depends on the date of import not the date of the email (am I right?).

Does anyone have an idea, that could help me?

Comments (6)

  1. Janos SUTO repo owner

    I know that it’s a bit late, however, the since then created imapfetch.py utility (it allows to download emails via imap protocol) has a search option, eg. “SINCE 19-Mar-2023”. Would it make sense to your use case, or would it be better to let pilerimport have a --before-date or --after-date option?

  2. Tom Jones reporter

    Dear Janos,

    I am really impressed that you got back to this request. Thanks for that!

    Unfortunately I currently do not have use for this feature, since I do not longer work for the company, where they use piler.

    But I suppose a filtering option within pilerimport might be of use for many users. I have especially those users in mind that use Outlook and have a bunch of pst-files to import. In my opinion it would be of great help to filter out unnecessary mails that otherwise consume space and create data overhead that is not needed in an e-mail archive.

  3. Janos SUTO repo owner

    I’ve added this feature to the master branch. Btw. maybe you could propose for your employer that it might be useful to start archiving emails ;-)

  4. Log in to comment