I recently discovered cli email clients and have fallen in love with their speed and simplicity. After playing around with mutt and alpine I decided I favor alpine. I am a Gmail IMAP user and have many years of emails that I'd like to store locally. Is there a more or less convenient way to retain IMAP functionality and backup only the emails that haven't been backed up already on a weekly basis? I have alpine setup with my Gmail with IMAP and it's working great. I'm just wondering if there is a way to make an offline backup or "archive" locally on my computer while retaining the multi device access that IMAP offers. I apologize if this has been asked before, I did search for it and did not find my answer. Thank you for reading.
Alpine isn't very suited for this – it's for reading mail, not automating backups. Try OfflineIMAP; it will not conflict with Alpine's access.
[general] accounts = Gmail [Account Gmail] localrepository = backup remoterepository = Gmail [Repository backup] type = Maildir localfolders = ~/Backup/mail [Repository Gmail] type = Gmail remoteuser = email@example.com readonly = True
Alternative: fetchmail. It's in every major distro.
You might have to do that several times to get all your email for the first time. Once this is done, every time you type the command above, it will fetch only mail that has not been fetched so far.
This writes fetched mail to /var/spool/mail/.