Here’s a nice guide to do just that.

Basically it just requires installing sendemail with

sudo apt-get install sendemail

and then finding the address of your ISPs email server. Now use this command:

sendEmail -f abcdefghij@gmail.com -t klmnopqrst@gmail.com -s mail2.eircom.net -u “Test” -m “This is a test with sendEmail from terminal”

Note that mail2.eircom.net is my ISPs email server. Obviously for most of you this’ll be different. This is denoted by the -s (Server) switch. Other switches used are -f (the “from” email address), -t (the ‘to” email address), -u (the email subject line) and -m (the actual email message).

Advertisement