How do I send email from the command line?
Posted on 16 January 2004 08:09 AM
I am used to sending email using SSH, but need to know how to do it at FutureQuest?
To send email via the command line at FutureQuest:
First, SSH to your account.
Once connected, then type:
(replace firstname.lastname@example.org with the address you wish to email)
When you press 'Enter' you will be prompted for a Subject. Type a short subject line, then press 'Enter' again. This will take you to a new line, and you may start typing the body of your email.
When you are ready to send the email, go to a new line (press Enter). Then type a period (.), and press 'Enter' again. You will then be prompted for a Carbon Copy (Cc:) addressee. If you wish to Cc the email, type that address and press 'Enter'. If you do not wish to Cc the email, simply press 'Enter' without typing anything. After pressing 'Enter', the message will be sent and you will be returned to the bash line.
[username@FQ-Seven:~ ]$ mail email@example.com
Subject: Command line email test
Here is the body of my email message
('Enter' pressed after each line.)