ITEM: D7910L

How can I get rid of Ctrl-M in file sent from PC to RISC?




Question:

        I have an RS/6000 and just used Xmodem to send files from a PC
to the RS/6000.  Now, the file on the RISC has Ctrl-M at the end of
each line.  How can I get rid of them?

Response:

        The easiest way to get rid of these is to mail the file to
yourself:

          mail [your username] \< filewithcontrolms

Then, save this mail message to another temp file.  Use vi to edit the
file and remove the top few lines of the mail header.  The file should
now be in the desired format.

Response:

Since the customer is not knowledgable in using mail facilities, and
the file is about 70,000 lines (making displaying the mail very
lengthy, the following commands may be used in a "vi" session to
do the same thing:

Use "vi" to display the file. Then type:

        :1,$s/\^V\^M//g   (where \^V is CTRL-V keys, likewise with \^M).

This will delete all \^Ms from the file. You can then save the file.


Support Line: How can I get rid of Ctrl-M in file sent from PC to RISC? ITEM: D7910L
Dated: September 1993 Category: N/A
This HTML file was generated 99/06/24~13:30:55
Comments or suggestions? Contact us