Setting up GNUS in Emacs
This week, I decided that I want to setup gnus at any cost. It must be able to fetch news from some news server and send/receive emails from my personal domain.
I managed to do that! I also uploaded my .emacs to GitHub which came in handy as I migrated from Linux Mint to Debian Jessie.
Basically, you need to setup only a few things to get gnus working - your email address, name, passwords, IMAP/POP3 server addresses & ports and nntp news server.
I searched way too much to understand what all I needed. There is a fine tutorial on the EmacsWiki. And I combined the info from there with Sacha’s post. And created the following ~/.gnus:
First, we are setting up primary method as null. Then, we setup two things - nntp and nnimap.
nntp fetches news from gmane and nnimap operates our email account via IMAP. You could just as well use POP3 with appropriate changes. We also enable SSL support for IMAP by doing (nnimap-stream ssl) and use login as authentication method. Pretty basic stuff.
Then, we need to setup SMTP to be able to send emails from gnus. I couldn’t use SSL ports here because my local machine does not have any certificate issued which caused errors in gnus (wasted more than an hour on this). So I changed to non-secure server/port and everything worked fine.
Make your ~/.authinfo like so:
machine a.abc.com login [email protected] password whattaysecret machine a.abc.com login [email protected] password whattaysecret port 993 machine a.abc.com login [email protected] password whattaysecret port 465 machine mail.abc.com login [email protected] password whattaysecret port 587
That’s it this should get you up and running!
Here are a few keybindings that you might find particularly useful:
m - new message ^ - browser server a - new article r - reply email f - reply to article C-c C-k - cancel message C-c C-c - send message <space> - scroll through messages c - mark as read (catch up) C-c C-s - sign message
Again, the tutorial and manual are proper resources for this. Join us in the #emacs IRC, and people will help you out if you’re stuck.
Oh, I also setup Python this week, but all I needed was elpy so that was 5 min work.
Have fun!