Linux Ask!

Linux Ask! is a Q & A web site specific for Linux related questions. Questions are collected, answered and audited by experienced Linux users.

Convert Windows text file to UNIX format without dos2unix

Answer:

As explained in this post, conversion using dos2unix is needed to convert file edited from Windows platform.

However, a simple command also can do the same job

# cat input.pl | col -b > output.pl
  1. Convert DOS/MAC to UNIX text file format converter
  2. Convert DOS newlines to Unix format
  3. Convert a Nero .nrg file to .iso file
  4. Simple file encryption with OpenSSL
  5. Give line numbers to a text file

Leave a Reply

(required)

(required)

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>