Maintains maildir archives synced with current maildirs
git clone https://git.8pit.net/archive-mail.git
1#!/bin/sh 2. "${0%/*}/common.sh" 3 4mmkdir current1 archive1 expected1 \ 5 current2 archive2 expected2 6 7add_mail current2/cur/1:2, archive1/cur/1:2, expected2/cur/1:2, <<-EOF 8 From: Hans Acker <hans@example.com> 9 Subject: Moved between maildirs10 Date: Thu, 23 Mar 2023 15:42:23 +020011 Message-Id: <EOH1F3NUOY.2KBVMHSBFATNY@example.org>1213 This message was in maildir1 and moved to maildir2.14EOF1516add_mail current1/cur/2:2, archive1/cur/2:2, expected1/cur/2:2, <<-EOF17 From: Some One <example@example.com>18 Subject: Unmodified Message v119 Date: Mon, 23 Dez 2313 12:23:42 +020020 Message-Id: <RADNE23UOY.2KBVMHSBFATNY@example.org>2122 This message is already in the archive.23EOF2425add_mail current2/cur/3:2, expected2/cur/3:2, expected2/cur/3:2, <<-EOF26 From: Some One <example@example.com>27 Subject: Unmodified Message v228 Date: Mon, 23 Dez 2314 12:23:42 +020029 Message-Id: <RADNE23UOY.2KBV29410ATNY@example.org>3031 This message is already in the archive.32EOF3334"${ARCHIVE_MAIL}" current1→archive1 current2→archive235check_maildir archive1 expected136check_maildir archive2 expected2