C:\tmp\text>dos2unix hello.txt helloUNIX.txt
Sed is even more widely available andcan do this kind of thing also if dos2unix is not installed
C:\tmp\text>sed s/\r// hello.txt > helloUNIX.txt
You could also try tr:
cat hello.txt | tr -d \r > helloUNIX2.txt
Here are the results:
C:\tmp\text>dumphex hello.txt
00000000h: 48 61 68 61 0D 0A 68 61 68 61 0D 0A 68 61 68 61 Haha..haha..haha
00000010h: 0D 0A 0D 0A 68 61 68 61 0D 0A ....haha..
C:\tmp\text>dumphex helloUNIX.txt
00000000h: 48 61 68 61 0A 68 61 68 61 0A 68 61 68 61 0A 0A Haha.haha.haha..
00000010h: 68 61 68 61 0A haha.
C:\tmp\text>dumphex helloUNIX2.txt
00000000h: 48 61 68 61 0A 68 61 68 61 0A 68 61 68 61 0A 0A Haha.haha.haha..
00000010h: 68 61 68 61 0A haha.