two files as a message in mail

Thread Tools Search this Thread
Top Forums Shell Programming and Scripting two files as a message in mail
# 1  
Old 12-13-2007
two files as a message in mail

i have two files --file1 and file2--

how should i send both the contents of files as a message in the mail body

i have written the script

mail -s "the two files are" < file1 < file2

this not working.plz help me

Last edited by ali560045; 12-13-2007 at 03:39 AM..
# 2  
Old 12-13-2007
cat file1 file2 | mail -s "the two files are"

# 3  
Old 12-13-2007
thanks for ur reply...................
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

sed to extract a multiline subject from a mail message

I'm trying to extract a subject from a mail message but my subject example has 2 lines. How can I manage to extract it and write a string at the end of it? Consider this example: From: Subject: Re: U =?ISO-8859-1?Q?qu=EA=3F!=3F!=3F!!_wtff_=E7=E3o_=ED=F3?= ... (6 Replies)
Discussion started by: twisterbr
6 Replies

2. Shell Programming and Scripting

sending multiple files along with mail message using uuencode

Hi, I have a requirement to send a mail with multiple files attached to it and along with the text message in the mail. I am trying sumthing like below but it only sends me the text message and no files attached to the mail. ---------------------------------------- ( uuencode file1... (1 Reply)
Discussion started by: sachinkl
1 Replies

3. Shell Programming and Scripting

Turn Off the Message [YOU HAVE NEW MAIL]

#!/bin/sh cd /u02/app/ccalloc/dev/in CURDIR=`pwd` echo directory listing of $CURDIR echo ls -latr i have a basic shell script that displays a specific files on a directory. when the script is run and it does not find the file in the directory it display a first line message of how... (3 Replies)
Discussion started by: wtolentino
3 Replies

4. Shell Programming and Scripting

Mail Message

Hi, Need a script bash,sh or perl doesn't metter, witch can read mail message text file and grep message body. Does it possible? (0 Replies)
Discussion started by: Mirror
0 Replies

5. UNIX for Dummies Questions & Answers

Return mail message

Hi I would like to know how interpret line by line a return mail message sent by unix mailer-daemon (2 Replies)
Discussion started by: alcvrjo
2 Replies

6. Shell Programming and Scripting

How to send a mail with attachement as well as message Body..?

Hi all, i am working with CSH, i want to know that how to send a mail in UNIX shell script (CSH) with attachment as well as message body. i know that how to send a mail with attachment and message body. but i want know both things in a single mail Suggession would be appreciate. ... (1 Reply)
Discussion started by: psiva_arul
1 Replies

7. Shell Programming and Scripting

pick correct message and mail.

Hi, I have the following small script. How can I just print out the string with missing message and send to Also, can i set the message a bit more beautiful such as "Dear All, the following list is missing in our system"? #!/bin/sh MSG=/log cat list11.txt | awk ' BEGIN { flag... (2 Replies)
Discussion started by: happyv
2 Replies

8. Shell Programming and Scripting

Crontab Mail message

Hi When I make change in crontab entries , I get below message as a mail. Can any one tell me what this indicates? ********************************************* From wlsdev05 Fri Sep 22 02:11:23 2006 Date: Fri, 22 Sep 2006 02:11:23 -0400 (EDT) From: "Geff Thomson - " <wlsdev05>... (1 Reply)
Discussion started by: pankajkrmishra
1 Replies

9. Shell Programming and Scripting

mail message attachment not complete

Hi, I use MIME::Lite to send an e-mail with an attachment: $msg = MIME::Lite->new( From =>$usermail, To =>$tomail, Subject =>'Nieuw Pegasus Adresboek', Type =>'multipart/mixed' ); $msg->attach(Type =>'TEXT', Data =>$message ); $msg->attach(Type =>'text/plain', Path... (4 Replies)
Discussion started by: tine
4 Replies

10. UNIX for Dummies Questions & Answers

How to get in e-mail message body

First of all: Hi all, im a new unix user and im swedish so please bare with me. When i generate an e-mail on a unix server and send it through novell netware 5, i loose the swedish characters , and in the body of the message, however they remain in the subject row. What to do? Anyone?... (4 Replies)
Discussion started by: de98luto
4 Replies
Login or Register to Ask a Question