PDA

View Full Version : Helpfull Tip With Moving showeq files from windows



ozz007
08-19-2004, 09:27 PM
Just a quick tip when moving files from a windows cd to a linux box. I ran into this when copying showeq from a cd off my windows notebook. The network connection was not established on the linux computer yet. I was having trouble with the ./configure file giving errors so I vi-ed the file and noticed ^M behind some of the lines. so I just did a

:
1,$s/[ctrl-v][Enter key]//g

and this removed all of the ^M's then I saved the changes with

:
w! ./configure

and it worked fine after that.


Oz

ksmith
08-19-2004, 09:57 PM
perl -spi -e 's/\r$//' filename

Cryonic
08-19-2004, 10:51 PM
dos2unix
unix2dos

I<3EQ
08-20-2004, 02:35 AM
tr -d '\r' windows_file.txt unix_file.txt

man tr if you wanna get more fancy. :D