Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I would like to use a terminal based mail client for my e-mail activities. I've been suggested to use alpine for it. But how do I configure it in Ubuntu to read my gmail mails?

share|improve this question

1 Answer 1

up vote 2 down vote accepted

It's quite straightforward to configure Alpine to access your gmail account via the imap protocol, and there are many tutorials online such as this article.

As you probably know, the first thing to do is to go to the settings in your gmail account and make sure imap is enabled for your account.

Then fetch Alpine with

sudo apt-get install alpine

Alpine was developed at the University of Washington; it is a successor to the old Pine email program; more details are available here at the official site, although there is further development going on at the re-Alpine project. Indeed, the Alpine version in the repositories is re-Alpine version 2.02-3.1.


The following tutorial describes a minimal way to setup Alpine so that you can receive and send mail.

Start up Alpine in terminal by typing alpine, and you come to the main screen. From that main screen (M) go to setup (S) > add a new collection (L), as in the screenshot below. Add the name of the collection (Gmail) and imap.gmail.com:993/ssl/user=[email protected] in the server box (adding your proper gmail address of course).

Some guides such as this one and many others will recommend the novalidate-cert option to be added in the above imap line (and in the smtp line quoted later), but it is not necessary with the current version of Alpine, as there is no problem with the certificates.

enter image description here

Then go back to the main menu and go to setup > config (C) and place all your details in the appropriate boxes, as in the screenshot below, with this time adding also the smtp server (smtp.gmail.com:587/tls/user=[email protected]) and specifying your inbox path and personal name:

enter image description here

Now save and exit back to the menu. Now with this basic setup you should be able to read and send mail. If you want, you can exit the program and the load it up again to check everything has configured correctly, and the main screen should be something like this:

enter image description here

There are a lot more customisations that can be made and settings experimented with (the users' configuration file is .pinerc in the home folder), and you can even export Thunderbird mail to view in Alpine, as I discuss here:

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.