我有这样六,替换文本
template
template
template_results
template
文本,我需要它替换到这个
template_form
template_form
template_results
template_form
我怎么能代替template
每场比赛未后跟_
字符VI?
我试图像这样
:%s/template[^_]/template_form - Pattern not found
:%s/template\[^_]/template_form - Pattern not found
:%s/template[_]/template_form - This works, but the pattern is opposite of what I need
谢谢:)
GregHNZ提供了完整的答案。你也可以匹配'template [^ _] *'。 – Andre 2012-03-09 08:34:42