On Tue, Jan 25, 2022 at 12:02:34PM +0100, Marcus C. Gottwald wrote: > > Chris Green wrote (Sun 2022-Jan-23 10:46:33 +0000): > > > Both hierarchies will be on the same computer so it isn't an IMAP > > synchronisation tool I'm looking for. These are just directory trees > > full of maildir mailboxes. > > How about copying files on disk? > > You could use "find" and/or "grep" to find the messages (= files); > use hardlinks if you're sure that no message will be modified; use > reflinks if the filesystem supports them; or simply copy from your > current area to the archive again and again, if it's not too much > data; use "fdupes" to remove duplicates (= identical content in > differently named files) if there's a chance for duplicates being > created. > That's a point!
If I simply use rsync to copy my 'current' maildir hierarchy to the 'archive' hierarchy then only the newer files get copied, all the older ones will already be there. It might be worth running fdupes on the archive occasionally but I don't think duplicates would be a big problem, the occasional one won't matter anyway. All I need to do then is delete files older than whatever date I decide to 'archive' and the job's done! -- Chris Green