I use fetchmail.
My .fetchmailrc contains:
poll pop.gmail.com with proto POP3
user 'mcharlesr(_at_)gmail(_dot_)com' there with password
'a-two-factor-auth-key' is 'mcharlesr(_at_)gmail(_dot_)com' here options
fetchall ssl
and:
cat ~/bin/gmail
#!/bin/sh
# fetch from google
fetchmail --proto POP3 --mda "/usr/lib/mh/rcvstore -sequence gmail +inbox"
--logfile /var/tmp/gmail.log pop.gmail.com
scan gmail
===
_______________________________________________
Nmh-workers mailing list
Nmh-workers(_at_)nongnu(_dot_)org
https://lists.nongnu.org/mailman/listinfo/nmh-workers