我需要全部更换;到\n ,但 :%s/;/\n/gc
不起作用
最佳答案
见 http://vim.wikia.com/wiki/Search_and_replace
When searching: \n is newline, \r is CR (carriage return = Ctrl-M = ^M)
When replacing: \r is newline, \n is a null byte (0x00).
关于regex - vim 将字符替换为\n,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3965883/