I have a shell script that uses sendmail function to send email the code is as follows
mailalert(){
sendmail -F Sender-Name -it <<END_MESSAGE
To: Recipient@example.com
Subject: Subject
Message
END_MESSAGE
}
It gets executed whenever I call this function. Now I have a text file which I want to send using sendmail as attachment or as message in the email it sends. How can I do that? I have tried alot of tricks but nothing seems to work. Please Help.
uuencode: not found
. – Tarun Oct 09 '13 at 13:54sudo apt-get install sharutils
then try again.@Tarun – Raja G Oct 09 '13 at 13:57begin 644 /path/filename.txt
and the cursor keeps on blinking. – Tarun Oct 09 '13 at 14:21