Instructions 3, 5 from here
Instruction 6 from here
- Install mutt
sudo apt-get install mutt
-
Create email account (mail.com is the setup used here)
-
Create folder
sudo touch /var/mail/<username>
sudo chmod 660 /var/mail/<username>
sudo chown `whoami`:mail /var/mail/<username>
- Create mutt configuration file
sudo vi ~/.muttrc
- Fill mutt config file with correct info
Note: See additional .muttrc file.
-
Send email
- Compose message in a .txt file and save:
sudo vi email.txt
- Send with just message
echo "" | mutt -s "<Subject Line>" -i email.txt [email protected]
Thanks to: https://www.thegeekdiary.com/linux-unix-send-mail-with-attachment-using-mutt/
- Send with attachment
echo "" | mutt -s "<Subject Line>" -i email.txt -a Attachment.txt [email protected]