home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!fuug!demos!kiae!glas!demos!jhunix.hcf.jhu.edu!kuo_wy
- From: kuo_wy@jhunix.hcf.jhu.edu
- Newsgroups: comp.unix.questions
- Date: 18 Jul 92 01:54 MDT
- Subject: Removing control codes, underscores
- Sender: Notesfile to Usenet Gateway <notes@glas.apc.org>
- Message-ID: <1992Jul17.215441.2717@jhunix.hcf>
- Nf-ID: #N:1992Jul17.215441.2717@jhunix.hcf:1752817653:001:1033
- Nf-From: jhunix.hcf.jhu.edu!kuo_wy Jul 18 01:54:00 1992
- Lines: 32
-
-
- Hi. I was wondering if anyone could help me with the following problem.
- I'd like to be able to print a man file or ftp it do a Macintosh for
- viewing.
- Suppose I man command > temp
- Then, lpr temp.
- What I receive on the printout is, e.g.:
- KKKKSSSSHHHH SSSSiiiilllliiiiccccoooonnnn
- GGGGrrrraaaapppphhhhiiiiccccssss
-
- _K_s_h_ is a...
-
- and so on, if I did man ksh > temp.
-
- If I ftp the file to a Mac, transferring it in ascii mode, and
- view the file with Microsoft Word 4.0, I get the following:
- K*K*K*K*S*S*S*S*...
- and _*K_*s_*h...
-
- and so forth, where * represents some unknown control character which
- is the same for everything.
-
- So, my question is how do I remove the repeated characters, the underscores
- and the control codes? I could always do a search and replace with
- Microsoft Word or pg the file and cut and paste to an MS Word document,
- but as both of these solutions are rather tedious, I was wondering if
- anyone could write a Korn shell script for me to do the job.
-
- Please e-mail your reply, and thanks in advance.
-
- Wilbur
-
-