11-02-2010
For me the mailx without the -m delivers the uuencode output as a body text blob not an attachment. Maybe there is a way to work around using sendmail, or an open source mailx with -m or other mail client or other attachment capabilities.
A mail message is just a pile of text, but the clients keep you out of the headers. I have cheated using mailx -s to stick a subject, linefeed and then an importance into the header, so I suppose you could stick a whole collection of files into the header, just by emulating the text of a mail message with attachments located before the body (why not?)! After all, encoded files have no quotes in the output, so $2 is just a very long string. I have written shell scripts to disassemble email with attached word and excel, with a little help from c base 64 decoder and open source word and excel decoders, so assembling should not be that hard.
Google showed me mutt and smtp-cli, which look pretty easy to use:
How to send email from the Linux command line – Simple Help
smtp-cli — command line SMTP client
Man Page for mutt (All Section 1) - The UNIX and Linux Forums
The Mutt E-Mail Client
This has an interesting comment about uuencode being unstable in email, and in modern email base64 seems to be more common:
http://systembash.com/content/linux-...h-files-email/
Last edited by DGPickett; 11-02-2010 at 11:44 AM..
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi Everyone,
I'm using the uuencode command with the mail command to send out emails through a UNIX script. The problems is that i have a number of gif files that i need to attach to a single email but the number and name of the gif files is not static. Example today the folder home/Desktop may... (4 Replies)
Discussion started by: nbvcxzdz
4 Replies
2. Shell Programming and Scripting
Hi All,
I am currently using the following script to send the single file to one/more email addresses. I need to send mutilple files at same time, are there anyway I could modify the script or write new one to accomplish the same.
Script
***************
#!/bin/ksh
# Author: Manish... (4 Replies)
Discussion started by: lapisguy
4 Replies
3. Shell Programming and Scripting
Hi,
I would like to send an email with more than one attachement. I am using uuencode. I want to achive by suing uuencode. Also please let me know other ways.
-Thambi (7 Replies)
Discussion started by: thambi
7 Replies
4. HP-UX
Hi,
I am executing the following command in order to send a file as an attachment:
mailx -s "Subject" emailID@xyz.com < Testfile.txt
Instead of attaching the file Testfile.txt, it is writing the contents of the file in the email message body. Please advise on how I can send the file as an... (7 Replies)
Discussion started by: sangharsh
7 Replies
5. HP-UX
Hi,
I am trying to send an email to multiple IDs from Unix script. I have given the EmailIds in a file and trying to use the file as input in the script.
> cat Email
EmailID = "abc@xyz.com cbz@xyz.com"
In my script I have
. /Email
mailx -s "subj" $EmailID
This fails with the... (3 Replies)
Discussion started by: sangharsh
3 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I need to zip 4 files and send an email attaching the zipped files...
Pls help..
Win
---------- Post updated at 10:49 AM ---------- Previous update was at 10:36 AM ----------
Hi,
I need to convert 4 text files into xls,zip these 4 files and send an email attaching the... (2 Replies)
Discussion started by: win4luv
2 Replies
7. Shell Programming and Scripting
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
8. Solaris
Hi All,
I am pretty new to the mail service in Sun Solaris 5.10. If anybody help me in writing a script for the multiple recipient with subject and the body would be a helpful.
Kindly help...
Thanks in advance. :)
Warm Regards,
Pramod (5 Replies)
Discussion started by: Pramod_009
5 Replies
9. Shell Programming and Scripting
Hi All,
I want to send each file to each email id as below.
Instead of writing saparate 10 mail commands
can we do it in a simple step.
file1.csv to raghu.s@hps.com
file2.csv to kiran.m@hps.com
file3.csv to kenni.d@hps.com
file4.csv to rani.d@hps.com
file5.csv to sandya.s@hps.com... (2 Replies)
Discussion started by: ROCK_PLSQL
2 Replies
10. Shell Programming and Scripting
Hi All,
I want to send multiple CSV file using below code. In Result folder, we have multiple CSV files. However, I want to catch only Summary CSV files.
I was trying using *, % with different combination. However, not able to do so.
From below code, I could send only one file... (1 Reply)
Discussion started by: Swapnil Mawle
1 Replies
LEARN ABOUT DEBIAN
urlscan
URLSCAN(1) General Commands Manual URLSCAN(1)
NAME
urlscan - browse the URLs in an email message from a terminal
SYNOPSIS
urlscan [options] < message
urlscan [options] message
DESCRIPTION
urlscan accepts a single email message on standard input, then displays a terminal-based list of the URLs in the given message. Selecting
a URL will invoke sensible-browser(1) on it (and hence any browser specified in the BROWSER environment variable).
urlscan is primarily intended to be used with the mutt (1) mailreader, but it should work well with any terminal-based mail program.
urlscan is similar to urlview(1), but has the following additional features:
1. Support for more message encodings, such as quoted-printable and base64.
2. Extraction and display of the context surrounding each URL.
OPTIONS
-b, --background
Run the Web browser in the background, so you can select another URL without closing it (this will not work with terminal-based Web
browsers such as lynx, links, or w3m).
-c, --compact
Display a simple list of the extracted URLs, instead of showing the context of each URL.
MUTT INTEGRATION
To integrate urlscan with mutt, include the following two commands in ~/.muttrc:
macro index,pager cb "<pipe-message> urlscan<Enter>" "call urlscan to extract URLs out of a message"
macro attach,compose cb "<pipe-entry> urlscan<Enter>" "call urlscan to extract URLs out of a message"
Once these lines are in your mutt configuration file, pressing Control-b will allow you to browse and open the URLs in the currently
selected message.
SEE ALSO
/usr/share/doc/urlscan/README, sensible-browser(1), urlview(1), mutt(1)
AUTHOR
This manual page was written by Daniel Burrows <dburrows@debian.org>.
December 10, 2006 URLSCAN(1)