Using mutt from command line or script


 
Thread Tools Search this Thread
Operating Systems AIX Using mutt from command line or script
# 8  
Old 02-27-2012
It can be implemented as a script. I just found this which may be of help:
https://www.unix.com/unix-dummies-que...-question.html

P.S. A little googling found other sed scripts too which do the job.
# 9  
Old 02-27-2012
I told you hours ago:

Code:
sed 's/$/\r/' unix.txt > win.txt

Have you tried adding carriage returns yet?
# 10  
Old 02-28-2012
And my response earlier was that the file already has a carriage return and line feed. I also found that mutt works with the command I showed earlier leaving the carriage return/line feeds in place so I only need to figure out how to place the "from" address in the email so that when it is received it has a "from" address. Thank you.

---------- Post updated 02-28-12 at 07:07 AM ---------- Previous update was 02-27-12 at 09:01 PM ----------

Hello all,
I was able to resolve my issue by setting a default email address in the Muttrc config file. This works for my purposes as I will be the only one sending email from this system. For others they will probably want to set up a person config file. The following command is what I end ed up with.
Code:
mutt -a pnc_data.txt -i mutt_body.txt -s "Test Email" my@somedomain.com < /dev/null

Thank you for your help.
# 11  
Old 02-28-2012
Quote:
Originally Posted by jyoung
And my response earlier was that the file already has a carriage return and line feed.
And my response earlier was that uuencode is a method of encoding binary files so ought to translate verbatim. If you aren't willing to even try...
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Mutt command email body

Hi Team, While sending the email using the mutt command, mail body not appearing properly and attachment it is showing without line breaks and i used the CSS Style (nowrapper )it is working fine. in this case how to handle the email body, please help me. (1 Reply)
Discussion started by: bmk123
1 Replies

2. Shell Programming and Scripting

How to send the log as it is through mailx or mutt command?

Hi, I am able to send the mail with attachment through mailx/mutt command.But i am seeing the log file statements all together when i tried to open from my outlook. log file have the details like below aaa bbb ccc when i tried to open it from my outlook after receiving the mail attachment... (1 Reply)
Discussion started by: Samah
1 Replies

3. UNIX for Beginners Questions & Answers

Exec command with mutt - turn on & off?

Hi Folks - Quick question around the exec command again. At the end of my script, I check for specific error codes that are returned from a process I execute within the shell script. Based on the error code, I send an email. Do I need to turn off exec feature prior to send each email so... (5 Replies)
Discussion started by: SIMMS7400
5 Replies

4. Shell Programming and Scripting

Mutt command error

Hello there, I am using "mutt" command to send e-mails. mutt -s "Mail subject line" $( printf -- '-a attachment_name') < "mail body file" "e-mail id" I wish to change the name of the attachment by appending the date to it. Something like "attachment_name_$DATE.html" in the mutt... (5 Replies)
Discussion started by: H squared
5 Replies

5. UNIX for Dummies Questions & Answers

Mutt command - email body with out file name

Hello All, I know we can put body inside a mail using -i option for specifying the file which contains body message, is there an option for me to specify body content instead of a file specification only using mutt? Below is not working and i don't see any options in manual page! ... (4 Replies)
Discussion started by: Ariean
4 Replies

6. UNIX for Advanced & Expert Users

HTML and attachment using mutt command

Hi All, I want to attach the file as well send html content in the mail body using mutt command or any other command.(uuencode is not present). Please help me. Thanks in advance (1 Reply)
Discussion started by: arukuku
1 Replies

7. Shell Programming and Scripting

How to change the sender's name or E-mail address in mutt command

Can any one help me in this ??? How to change sender's name or email address in Mutt command??? (4 Replies)
Discussion started by: sarathi
4 Replies

8. Shell Programming and Scripting

How to split a csv file and zip it and attach using mutt command?

We need to redirect the output of a query to .csv file each containing a specified number of lines.Then we should zip these files and send as attachment using mutt command. We tried using split -l 500 query_output.txt outputfile Since we are not sure about the exact number of files... (0 Replies)
Discussion started by: Jassz
0 Replies

9. Shell Programming and Scripting

How to attach multiple .csv files using mutt command

I need to attach all files starting with 'BusinessReport' using mutt command. It could be any number of files in that directory, say BusinessReport_01, BusinessReport_03, BusinessReport_04 etc. Is there a way to attach all files where filename like BusinessReport_* and sent it using mutt... (2 Replies)
Discussion started by: Jassz
2 Replies

10. Shell Programming and Scripting

How does mutt command pick senders Details

Hi All, We use mutt in one of our scripts to send files as a part of a batch job . The command works nicely but i want to know from where does mutt pick the sender details. As the sender id is different if i use mutt and Mail utility. I can not change the command to mail as it is a part of the... (1 Reply)
Discussion started by: amit1_x
1 Replies
Login or Register to Ask a Question