0

how to attach a file in mail command

How can I attach some files to send through mail command???

Email server Add a comment
liam
asked May 11 2017

Answer

0

Assume if you have test.txt file in /home/user1/Documents and you can send it through mail command as follows,

# mail -s "File attached" -a /home/suer1/Documents/test.txt abc@gmail.com
 A File had been attached.
 EOF

Now check the mail with a file attached.

Add a comment
jagannatharumugam
asked May 11 2017
edited Oct 05 2018
Post your Answer