How to use the command line to access Gmail

  
under Linux

If you like to use the command line, I believe that you will be accustomed to using the Linux command line to perform every daily task, whether it is scheduling or managing finances or getting Facebook, Twitter and other tasks. . Of course, you can also use the command line to access Gmail to send and receive mail. In this article, I'll show you another nice and clever use case for the Linux command line: Visit Google's Gmail service, for which we'll use Alpine, a multi-function command-line mail client based on ncurses (don't Confused with Alpine Linux). We will configure Gmail's IMAP and SMTP settings in Alphine to receive and send mail in the terminal environment via Google's mail server. At the end of this tutorial, you will find that other mail services can be used in Alpine in just a few steps.

Sure, there are many excellent GUI-based mail clients, such as Thunderbird, Evolution or even a web interface, so why do people have to use the command-line mail client to charge Gmail? Interest? The answer is simple. If you need to handle things quickly and avoid wasting unnecessary system resources; or if you are working on a thin-installed consoleless server, it does not have an X service for graphical display; or an X service is available to you. The desktop crashes, and you need to send some emails eagerly before solving this problem. In all of the above cases, Alpine can come in handy and meet your needs at any time.

In addition to simple editing, sending and receiving text messages, Alpine can also encrypt, decrypt and digitally sign email messages, as well as with TLS (Note: Transport Layer Security, transport layer) Encryption) Seamless integration.

Installing Alpine on Linux

On Red Hat-based distributions, you can install Alpine as follows. It's important to note that on RHEL or CentOS you need to enable the EPEL depot first.

# yum install alpine

On Debian, Ubuntu or their derivative distributions, you can do this:

# aptitude install alpine

After the installation is complete, you can run the following command to start the mail client:

# alpine

When you first enable Alpine, it will be created in the current user's home directory. A mail folder (~/mail) and the main interface appears, as shown in the video below: YOUTUBU video - http://www.youtube.com/kuKiv3uze4U .

Its user interface has the following several modules:

Please feel free to browse, to become familiar with the operation Alpine. You can always go back to the command prompt interface by typing ‘Q’ at any time. Please note that there are operational-related help below all of the character interfaces.

We will create a default configuration file for Alpine before going further. To do this, close Alpine and execute the following command from the command line:

# alpine -conf 》 /etc/pine.conf Previous123Next page Total 3 pages

Copyright © Windows knowledge All Rights Reserved