linuxunixcontrol-mdos2unix

Add Control M character in a text file


Hi I am trying to add Control M character in a text file using Putty. I tried to do Ctrl-v Ctrl-M but as soon as I do this it goes out of putty to my desktop home.Can anyone please tell me how to add Ctrl M character in a file


Solution

  • The easiest way would probably be to use the unix2dos utility:

    $ unix2dos myfile.txt