在Vim我有:
simulación (fig.),pretexto (fig.),excusa (fig.).
Run Code Online (Sandbox Code Playgroud)
我的目标是:
simulación ,pretexto ,excusa .
Run Code Online (Sandbox Code Playgroud)
我尝试过::%s/\(fig\.\)//g,但它不起作用.
DrA*_*rAl 54
默认情况下,Vim不需要转义括号.尝试:
:%s/(fig\.)//g
Run Code Online (Sandbox Code Playgroud)
看到:
:help magic
Run Code Online (Sandbox Code Playgroud)
编辑
添加反斜杠转义点.
不要逃避parens - vim默认使用"魔术"转义方案.尝试:
:%s/(fig\.)//g
Run Code Online (Sandbox Code Playgroud)
更多信息:http://vimdoc.sourceforge.net/htmldoc/pattern.html#/\v