Sendmail isn't responsible for attaching attachments to e-mail - it's up to the mail user agent (mail client) to attach items to e-mail messages. Sendmail is just the transport.<br>
<br>
If you're using sendmail as a mail client, you should really consider taking a look at mail, mailx, or, even better, pine.<br>
<br>
Out of interest, to send an attachment to an e-mail from the command line, you could uuencode it as follows:<br>
<br>
echo "This is my attachment:\n\n`uuencode myattachment myattachment`" ¦ mailx -s"Test sending uuencoded attachment" <A HREF="mailto:someone@somewhere.com">someone@somewhere.com</A>
To add to the jmccreary's questions: I create filename.txt files on an AIX box and want to email these files not as text but attachments to an nt exchange user. I have aliases for the users to route the mail or mailx messages but do not understand how to attach the file, I only get the content of the files. Sorry to add to the question, not to the solution.
Why not try Pine? It's a nice little mail client, runs from the console or in a terminal window, and attachments are as easy as CTRL-J... Are you just interested in a way to attach files from the command line?
On our AIX box, inside our software, I setup pseudo printers for each user (see below) and aliases with the unix id=exchange email address.
Example for user 80. This is a .SH on our system for user 080, I called it 080email.sh, it is called as a printer and emails any report output to the user as an attachment called TRENDRPT.WRI with a RE of Trend Auto Report. I picked WRI as it was not commonly used by other programs in our environment.
uuencode $2 TRENDRPT.WRI | mail -s "Trend Auto Report" 080
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.