On 2/20/20 3:12 PM, rance.hall@esu10.org wrote:
Now for the question/hard part. Migrating list archives.
In Sympa the list archive is just a maildir format directory structure reflecting month/year. In MM3 the Archive is stored in the db with attributes that are likely only available as the message is processed.
I'd really rather not loose the archive data if I can help it. Does anyone have any thoughts on how I could perhaps import this?
It shouldn't be hard. HyperKitty has a function to import archive mbox files. It would be a simple matter to use Python's mailbox module to convert your archive. Something like
import mailbox md = mailbox.Maildir('path/to/maildir/directory', create=False) mb = mailbox.mbox('path/to/mbox', create=True) for msg in md: mb.add(msg) mb.close() md.close()
Then just run hyperkitty_import to import the mbox. run something like
django-admin hyperkitty_import --help
for details. Note that if there are already archived messages you need to specify --since to import older messages.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan