From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <96078611110560.tru64-unix-managers.marc@archive.invalid> From: George Gallen Date: Fri, 18 Apr 1997 16:18:00 +0000 To: tru64-unix-managers Subject: unix2dos, Can it be used to not alter original file? X-MARC-Message: https://marc.info/?l=tru64-unix-managers&m=96078611110560 I have tried multiple ways using redirection and piping, but to no avail, I have also tried using MTOOLS mcopy (with the t option) to create a temp file, but it seems you cant use mcopy to go unix->unix. What am I trying to do? I want to email a file as an attachment (ie). and have the lf converted to lf/cr (the file will be read on an MSDOS machine). Ultimatly I want to be able to do something like.... unix2dos origfile | uuencode OUTPUTNAME | mailx -s xxx user@domain I tried using sed (which worked excellent from the command line) but..... I am attempting to use this from a shell from a database program, which I cannot embedd ^V^M for sed to do its stuff. I tried adding the sed command as an alias to my .cshrc file, but I can't get to function correctly (this way instead of embedding ^V^M I could use a preset alias) : alias unix2dos "/usr/bin/sed -e 's/$/^M/'" (the ^M is typed in as ^V^M) (which gives "varible syntax" when sourced). SO....... What am I doing wrong with my alias.........or How do you get unix2dos to not change original file.......or Can Mtools be used (with t option) to do lf->cr/lf while doing unix->unix. Not too tough I hope. George Gallen ggallen@slackinc.com