change the line ux2dos $1 | uuencode $1.txt >> temp.txt
to ux2dos $1 >> temp.txt

i think uuencode $1.txt is just for the encoding of characters.


On Thu, 2003-09-18 at 15:01, Tapang, Roderick (GXS) wrote:
> hi gurus,
> 
> i have a small ksh script that sends a file as an attachment.
> how do i eliminate the portion where it writes a file on the
> disk  just to add the .txt extension?
> 
> here is the current:
> #
> #####
> if [ $# != 2 ] || [ ! -a $1 ]
> then
>         print "$USAGE"
>         exit 1
> fi
> 
> ux2dos $1 | uuencode $1.txt >> temp.txt
> mail $2 < temp.txt
> #####
> 
> ex:
> file on disk:
> 
> cache/file1
> 
> target add -  [EMAIL PROTECTED]:
> 
> send.sh cache/file1 [EMAIL PROTECTED]
> 
> (will send file1.txt as an attachment)
> 
> thanks!
> 
> erik
> 
> --
> Philippine Linux Users' Group (PLUG) Mailing List
> [EMAIL PROTECTED] (#PLUG @ irc.free.net.ph)
> Official Website: http://plug.linux.org.ph
> Searchable Archives: http://marc.free.net.ph
> .
> To leave, go to http://lists.q-linux.com/mailman/listinfo/plug
> .
> Are you a Linux newbie? To join the newbie list, go to
> http://lists.q-linux.com/mailman/listinfo/ph-linux-newbie

--
Philippine Linux Users' Group (PLUG) Mailing List
[EMAIL PROTECTED] (#PLUG @ irc.free.net.ph)
Official Website: http://plug.linux.org.ph
Searchable Archives: http://marc.free.net.ph
.
To leave, go to http://lists.q-linux.com/mailman/listinfo/plug
.
Are you a Linux newbie? To join the newbie list, go to
http://lists.q-linux.com/mailman/listinfo/ph-linux-newbie

Reply via email to