我要利用s(替换)功能。
例如,我写代码,希望所有字符串都是大写字母开头。
string str1="hello world";
string anotherString="do you know me?";
通过s、正则表达式、以及我要问的功能,上述代码能变成
string str1="Hello world";
string anotherString="Do you know me?";
所以可以怎么做?
具体来说,就是怎么把正则捕获到的分组转换为大写或小写。
Vim如何替换为大写或小写
-
- 帖子: 84
- 注册时间: 2011-02-17 9:11
- lilydjwg
- 论坛版主
- 帖子: 4249
- 注册时间: 2009-04-11 23:46
- 系统: Arch Linux
- 联系: