gVim showing carriage return (^M) even when file mode is explicitly DOS

前端 未结 10 1465
小蘑菇
小蘑菇 2020-12-22 15:25

I\'m using gVim on Windows. My code shows ^M characters at the end of lines. I used :set ff=dos to no avail. The ^M characters remain

10条回答
  •  时光取名叫无心
    2020-12-22 15:57

    Running Vim 7.3 on Windows 7. I used the following command:

    :%s/^M/\r/g
    

    To create the ^M I typed in CTRL+Q then CTRL+M.

提交回复
热议问题