script to move messages according to tags

David Edmondson dme at dme.org
Wed Dec 11 07:33:23 PST 2019


On Wednesday, 2019-12-11 at 16:28:20 +01, Alan Schmitt wrote:

> I do have one small question: how do you deal with mails that have
> duplicates? For instance, when I send a mail to a mailing list, I end
> up with both the sent email and the one I later receive from the
> list. If I tag the send one with deleted (no need to keep it), won't I
> run the risk to delete both mails?

If you have the id of a message you can get a list of all of the
corresponding files with:
  notmuch search --exclude=false --output=files $id

How you decide to deal with multiple results is really up to you - in my
case I move/delete all of them (except that I don't actually delete
anything).

dme.
-- 
Our President's crazy, did you hear what he said?


More information about the notmuch mailing list