linux - Any command we can use to convert windows file to unix or mac file? -


I do not want to use the dos2unix tool. I want to use the command in the Ubuntu terminal so that the windows can be converted to a UNIX file. Is it possible. I looked through other articles and tried those commands, but nobody is working, anybody can help

You can use tr to remove the carriage return in this way:

  tr -d '\ r' & lt; Windows File & gt; UnixFile   

You can see the carousis return in your file by using

  cat -vet WindowsFile   

And they will appear as ^ M

Comments

Popular posts from this blog

Java - Error: no suitable method found for add(int, java.lang.String) -

java - JPA TypedQuery: Parameter value element did not match expected type -

c++ - static template member variable has internal linkage but is not defined -