November 16, 2022 6:15 PM, "Mekeor Melire" <mek...@posteo.de> wrote:
> Hello Guix, > > you might want to import a mailing-list-archive into mu4e. E.g. because > debbugs.el is slow, you might want to import the archives of the > guix-patches mailing list. This is how to do so. Hey thanks for sharing! How about we make this guide a bit more permanent? Would you mind writing this up and including it in the guix cookbook? Once you submit the patch, please CC me. I'll review it for you. Thanks again! Joshua > > First, download the archives as in the "mbox" format -- the only format > that Mailman offers: > > --8<---------------cut here---------------start------------->8--- > cd ~/some/where > for y in {2017..2022}; do > for m in {01..12}; do > curl --fail "https://lists.gnu.org/archive/mbox/guix-patches/$y-$m" > "$y-$m" > || rm "$y-$m"; > done; > done > --8<---------------cut here---------------end--------------->8--- > > Now, download and run a perl-tool named "mb2md" to convert the mboxes > into maildirs: > > --8<---------------cut here---------------start------------->8--- > mkdir tool maildir > curl http://batleth.sapienti-sat.org/projects/mb2md/mb2md-3.20.pl.gz \ > --output tool/mb2md.pl.gz > gzip -d tool/mb2md.pl.gz > chmod 755 tool/mb2md.pl > guix shell perl perl-datetime perl-timedate > for f in $(realpath ./mbox)/*; do > perl tool/mb2md.pl -s "$f" -d $(realpath mailbox); > done > exit > --8<---------------cut here---------------end--------------->8--- > > Next, you might want to mark all mails in that maildir as "read": > > --8<---------------cut here---------------start------------->8--- > guix shell mblaze > mlist -s ./mailbox | mflag -S > exit > --8<---------------cut here---------------end--------------->8--- > > Finally, move that maildir to its destination: > > --8<---------------cut here---------------start------------->8--- > mv maildir ~/path/to/maildirs/guix-patches > --8<---------------cut here---------------end--------------->8--- > > Enjoy!