{"id":14250,"date":"2021-01-03T17:03:10","date_gmt":"2021-01-03T09:03:10","guid":{"rendered":"http:\/\/blog.idc.net\/14250\/"},"modified":"2021-01-03T17:03:10","modified_gmt":"2021-01-03T09:03:10","slug":"%e5%9f%ba%e4%ba%8eubuntu-16-04-%e9%85%8d%e7%bd%ae-vim-ide","status":"publish","type":"post","link":"https:\/\/idc.net\/help\/14250\/","title":{"rendered":"\u57fa\u4e8eUbuntu 16.04 \u914d\u7f6e Vim IDE"},"content":{"rendered":"<div class=\"idc_table\">\n<h2>1.\u5e8f\u8a00 &nbsp; &nbsp; &nbsp; &nbsp;<\/h2>\n<p>\u672c\u6587\u662f\u672c\u4eba\u5728Ubuntu 16.04\u4e0aVim IDE\u642d\u5efa\u8fc7\u7a0b\u7684\u603b\u7ed3\u3002\u5728Windows\u73af\u5883\u5f00\u53d1\u7684\u5c0f\u4f19\u4f34\u4e5f\u8bb8\u90fd\u77e5\u9053sourceinsight\u8fd9\u6b3e\u7f16\u8f91\u5668\uff0c\u4e3a\u4e86\u63d0\u9ad8Linux\u4e0b\u5f00\u53d1\u6548\u7387\uff0c\u672c\u4eba\u642d\u5efa\u4e86\u7c7bsourceinsight\u7684IDE\u5f00\u53d1\u73af\u5883\uff08\u52c9\u5f3a\u79f0\u4f5cVIM IDE\u5427\uff1a\uff09\uff09\u3002<\/p>\n<p>\u5e9f\u8bdd\u4e0d\u591a\uff0c\u5148\u4e0a\u56fe\u5c55\u793a\u672c\u4eba\u7684VIM IDE\u3002 \u4e00\u4e2a\u7a97\u53e3\u540c\u65f6\u663e\u793a\u4e864\u4e2a\u5b50\u7ec8\u7aef\u7a97\u53e3\uff08\u5f53\u7136\u4e5f\u53ef\u4ee5\u6709\u66f4\u591a\uff09\uff0c\u6bcf\u4e00\u4e2a\u5b50\u7ec8\u7aef\u7a97\u53e3\u7c7b\u4f3csourceinsight\u53c8\u5207\u5206\u6210\u4e863\u680f\uff08\u5de6\u4e0bTaglist\u680f-\u663e\u793a\u51fd\u6570\uff0c\u5b8f\u7b49\u6807\u7b7e;\u5de6\u4e0afilelist\u680f-\u663e\u5f0f\u4ee3\u7801\u6587\u4ef6\u76ee\u5f55\u6587\u4ef6\u7ed3\u6784; \u53f3\u4fa7\u680f-\u4ee3\u7801\u7f16\u8f91\u533a\uff09\u3002 \u5982\u679c\u6211\u4eec\u770b\u7740\u7a97\u53e3\u5b57\u592a\u5c0f\uff0c\u6ca1\u5173\u7cfb\uff0c \u5f53\u7f16\u8f91\u7a0b\u5e8f\u65f6\u5019\u4f60\u53ef\u4ee5\u9009\u62e94\u4e2a\u5b50\u7ec8\u7aef\u7a97\u53e3\u4e2d\u8981\u7f16\u8f91\u7684\u90a3\u4e2a\u7ec8\u7aef\u5355\u72ec\u653e\u5927\u5168\u5c4f\u663e\u793a\uff08terminator\u5b89\u88c5\u540eCtrl+shit+X\uff09\uff0c\u7f16\u8f91\u5b8c\u6210\u4e4b\u540e\u4ecd\u7136\u53ef\u4ee5\u5207\u6362\u56de\u6765\uff08terminator\u5b89\u88c5\u540eCtrl+shift+Z\uff09\u3002<\/p>\n<h2>2. \u914d\u7f6e\u8fc7\u7a0b<\/h2>\n<p>&nbsp; &nbsp; \u5982\u679c\u8981\u5b8c\u6210\u4ee5\u4e0a\u663e\u793a\u6548\u679c\uff0c\u6211\u4eec\u9700\u8981\u5b89\u88c5\u4e00\u4e9b\u5fc5\u8981\u7684\u5de5\u5177\u548c\u63d2\u4ef6\uff0c\u4e0b\u9762\u5c06\u9010\u6b65\u5c55\u5f00\u3002<\/p>\n<h3>2.1 Terminator \u5b89\u88c5<\/h3>\n<p>&nbsp; &nbsp; &nbsp; \u5de5\u5177Terminator\u53ef\u4ee5\u5728\u4e00\u4e2a\u7a97\u53e3\u4e2d\u663e\u793a\u591a\u4e2a\u7ec8\u7aef\u7a97\u53e3\uff0c\u5e76\u4e14\u53ef\u4ee5\u6309\u7167\u7528\u6237\u7684\u8981\u6c42\u5bf9\u7a97\u53e3\u8fdb\u884c\u4efb\u610f\u5206\u5272\u3002<\/p>\n<p>&nbsp; &nbsp; &nbsp; Ubuntu\u73af\u5883\u5b89\u88c5terminator\u5de5\u5177\u547d\u4ee4\u4e3a\uff1asudo apt-get install terminator<\/p>\n<p>&nbsp; &nbsp; &nbsp; Terminator\u5e38\u7528\u5feb\u6377\u6309\u952e\u6709<span style=\"font-family: Tahoma\">\uff1a<\/span><\/p>\n<p><span style=\"font-family: Tahoma\">&nbsp; &nbsp; 1\uff09<\/span><span style=\"font-family: Tahoma\">Ctrl+<\/span>Shift+E\u5782\u76f4\u5206\u5272\u7a97\u53e3<\/p>\n<p><span style=\"line-height: normal\">&nbsp; &nbsp; &nbsp; 2\uff09<span style=\"font-family: Tahoma\">Ctrl<\/span>+<span style=\"font-family: Tahoma\">Shift<\/span>+<span style=\"font-family: Tahoma\">O<\/span> \u6c34\u5e73\u5206\u5272\u7a97\u53e3<\/span><\/p>\n<p><span style=\"line-height: normal\">&nbsp; &nbsp; &nbsp; 3\uff09Ctrl+Tab&nbsp; \u5728\u5206\u5272\u7684\u7a97\u53e3\u95f4\u5207\u6362<\/span><\/p>\n<p><span style=\"line-height: normal\">&nbsp; &nbsp; &nbsp; 4\uff09Ctrl+Shift+C\/V \u590d\u5236\/\u7c98\u8d34<\/span><\/p>\n<p><span style=\"line-height: normal\">&nbsp; &nbsp; &nbsp; 5\uff09Ctrl+Shift+X \u653e\u5927\u7a97\u53e3\u5230\u5168\u5c4f<\/span><\/p>\n<p><span style=\"line-height: normal\">&nbsp; &nbsp; &nbsp; 6\uff09Ctrl+Shift+Z \u4ece\u653e\u5927\u7a97\u53e3\u56de\u5230\u591a\u7a97\u53e3<\/span><\/p>\n<p>&nbsp; &nbsp; &nbsp; \u6ce8\u610f\uff1a\u5982\u679c\u60a8\u5bf9\u7a97\u53e3\u98ce\u683c\u4e0d\u6ee1\u610f\uff0c\u53ef\u4ee5\u53f3\u952e-&gt;preferences\u8fdb\u884c\u5fc5\u8981\u8bbe\u7f6e\u548c\u4fee\u6539\u3002\u6bd4\u5982\u4fee\u6539\u5feb\u6377\u6309\u952e\u7b49\u7b49\u3002<\/p>\n<h3>2.2 vim \u7f16\u8f91\u5668\u5b89\u88c5<\/h3>\n<p>&nbsp; &nbsp; &nbsp; Ubuntu\u73af\u5883\u5b89\u88c5terminator\u5de5\u5177\u547d\u4ee4\u4e3a\uff1a sudo apt-get install vim vim-scripts vim-doc<\/p>\n<p>&nbsp; &nbsp; &nbsp;\u5176\u4e2dvim-scripts\u662fvim\u7684\u4e00\u4e9b\u57fa\u672c\u63d2\u4ef6 \uff0cvim\u5b89\u88c5\u4e4b\u540e\u7d27\u63a5\u7740\u5e94\u8be5\u4e2a\u6027\u5316\u914d\u7f6e\u3002Vim\u672c\u8eab\u7684\u7cfb\u7edf\u914d\u7f6e\u6587\u4ef6\u5939\u662f\u5728\/usr\/share\/vim\/\u548c\/etc\/vim\/\u4e24\u4e2a\u6587\u4ef6\u5939\u4e0b\u3002\u4f46\u662f\u901a\u5e38\u6211\u4eec\u4e0d\u4f1a\u53bb\u6539\u53d8\u8fd9\u4e24\u4e2a\u6587\u4ef6\u5939\u4e0b\u7684\u914d\u7f6e\u6587\u4ef6\uff0c\u800c\u662f\u5728\u7528\u6237\u6587\u4ef6\u5939\/home\/user\u4e0b\u5efa\u7acb\u81ea\u5df1\u7684\u914d\u7f6e\u6587\u4ef6.vimrc\u7136\u540e\u5bf9\u5176\u914d\u7f6e\uff0c\u8fd9\u91cc\u4e0d\u518d\u89e3\u91ca\uff0c\u540e\u9762\u6211\u5c06\u9644\u4e0a\u6211\u7684vim\u914d\u7f6e\u3002<\/p>\n<h3>&nbsp;<\/h3>\n<h3>2.3 vim\u63d2\u4ef6\u5b89\u88c5<\/h3>\n<p>&nbsp; &nbsp; vim\u5e38\u7528\u63d2\u4ef6\u6709\uff1a1\uff09vim-addons 2)ctags 3)cscope 4)winmanager 5)minibufexplorer 6)omnicppcomplete 7)AutoComplPop&nbsp; 8)echofunc 9)taglist<\/p>\n<h4>2.3.1 vim-addons<\/h4>\n<p>&nbsp; \u901a\u8fc7vim-addons\uff0c\u6211\u4eec\u53ef\u4ee5\u7ba1\u7406vim\u63d2\u4ef6\u3002\u53ef\u901a\u8fc7\u547d\u4ee4sudo apt-get install vim-addon-manager\u624b\u52a8\u5b89\u88c5\u3002<\/p>\n<p>&nbsp; \u67e5\u770b\u63d2\u4ef6\u72b6\u6001 \u547d\u4ee4\uff1a vim-addons status<\/p>\n<p><span style=\"background-color: #c0c0c0\"># Name&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; User Status&nbsp; System Status<br \/>align&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>alternate&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>bufexplorer&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>calendar&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>closetag&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>colors-sampler-pack&nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>cvsmenu&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>debPlugin&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>detectindent&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>doxygen-toolkit&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>editexisting&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>enhanced-commentify&nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>gnupg&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>info&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>justify&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>lbdbq&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>matchit&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>minibufexplorer&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; installed&nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>nerd-commenter&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>omnicppcomplete&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; installed&nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>po&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>project&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; installed&nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>python-indent&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>secure-modelines&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>snippetsEmu&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>sokoban&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>supertab&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>surround&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>taglist&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; installed&nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>tetris&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>utl&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>vcscommand&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>vimplate&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>whatdomain&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>winmanager&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; installed&nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; &nbsp;<br \/>xmledit&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; removed&nbsp; &nbsp; &nbsp; removed<\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u5b89\u88c5\u67d0\u4e2a\u63d2\u4ef6X\u547d\u4ee4\uff08\u524d\u63d0\u662f\u5728\u76ee\u5f55\/home\/user\/.vim\/\u4e0b\u5efa\u7acb\u597d\u4e86plugin\u548cdoc\u4e24\u4e2a\u6587\u4ef6\u5939\uff09\uff1avim-addons install X<\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.2 ctags<\/span><\/span><\/h4>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; ctags\u7528\u6765\u5efa\u7acb\u6e90\u7801\u6811\u7684\u6807\u7b7e\u7d22\u5f15\uff08\u6807\u7b7e\u5c31\u662f\u4e00\u4e2a\u6807\u8bc6\u7b26\u88ab\u5b9a\u4e49\u7684\u5730\u65b9\uff0c\u5982\u51fd\u6570\u5b9a\u4e49\uff09\uff0c\u5728\u7f16\u7a0b\u65f6\u80fd\u8fc5\u901f\u5b9a\u4f4d\u51fd\u6570\u3001\u53d8\u91cf\u3001\u5b8f\u5b9a\u4e49\u7b49\u4f4d\u7f6e\u53bb\u67e5\u770b\u539f\u5f62\u3002<br \/>&nbsp; &nbsp; 1\uff09ctags\u5b89\u88c5\u547d\u4ee4<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; sudo apt-get install ctags<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 2\uff09ctags\u914d\u7f6e<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; \u8981\u6b63\u786e\u4f7f\u7528ctags\u529f\u80fd\uff0c\u6211\u4eec\u4e5f\u9700\u8981\u914d\u7f6evimrc\u6587\u4ef6\uff0c\u6211\u5c06\u5728\u9644\u4ef6\u5217\u4e3e\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 3\uff09\u5efa\u7acb\u9879\u76eeproject\u7684\u6e90\u7801\u7d22\u5f15\u547d\u4ee4\uff08\u901a\u5e38\u5728\u9879\u76eeproject\u6587\u4ef6\u5939\u6839\u76ee\u5f55\u6267\u884c\uff09<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; ctags -R *<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \u6267\u884c\u4ee5\u4e0a\u547d\u4ee4\u4e4b\u540e\uff0c\u4f60\u4f1a\u53d1\u73b0\u591a\u4e86\u4e00\u4e2atags\u6587\u4ef6\uff0c\u8fd9\u4e2a\u5c31\u662fctags\u7d22\u5f15\u6587\u4ef6\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 4\uff09ctags\u5e38\u7528\u65b9\u6cd5<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Ctrl\uff0b\uff3d&nbsp; \u8df3\u5230\u5f53\u524d\u5149\u6807\u4e0b\u5355\u8bcd\u7684\u6807\u7b7e<br \/>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Ctrl\uff0bO&nbsp; \u8fd4\u56de\u4e0a\u4e00\u4e2a\u6807\u7b7e<br \/>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Ctrl\uff0bT&nbsp; \u8fd4\u56de\u4e0a\u4e00\u4e2a\u6807\u7b7e<br \/>&nbsp; &nbsp; &nbsp; &nbsp; Ctrl\uff0bW + \uff3d&nbsp; \u65b0\u7a97\u53e3\u663e\u793a\u5f53\u524d\u5149\u6807\u4e0b\u5355\u8bcd\u7684\u6807\u7b7e\uff0c\u5149\u6807\u8df3\u5230\u6807\u7b7e\u5904<\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.3 cscope<\/span><\/span><\/h4>\n<p>&nbsp; &nbsp; &nbsp; cscope\u662f\u7c7b\u4f3c\u4e8ectags\u4e00\u6837\u7684\u5de5\u5177\uff0c\u4f46\ufffd\ufffd\u6bd4ctags\u66f4\u5f3a\u5927\u3002<\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp;<span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">1\uff09cscope\u5b89\u88c5\u547d\u4ee4<\/span><\/span><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; sudo apt-get install cscope<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 2\uff09cscope\u914d\u7f6e<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; \u8981\u6b63\u786e\u4f7f\u7528cscope\u529f\u80fd\uff0c\u6211\u4eec\u4e5f\u9700\u8981\u914d\u7f6evimrc\u6587\u4ef6\uff0c\u6211\u5c06\u5728\u9644\u4ef6\u5217\u4e3e\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 3\uff09\u5efa\u7acb\u9879\u76eeproject\u7684\u6e90\u7801cscope\u6570\u636e\u5e93\u547d\u4ee4\uff08\u901a\u5e38\u5728\u9879\u76eeproject\u6587\u4ef6\u5939\u6839\u76ee\u5f55\u6267\u884c\uff09<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; cscope -Rbq cscope.out<br \/><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \u6267\u884c\u4ee5\u4e0a\u547d\u4ee4\u4e4b\u540e\uff0c\u4f60\u4f1a\u53d1\u73b0\u591a\u4e863\u4e2a\u6587\u4ef6\uff0ccscope.in.out\uff0ccscope.po.out\uff0c&nbsp;cscope.out\uff0c \u5b83\u4eec\u5c31\u662fcscope\u7d22\u5f15\u6570\u636e\u5e93\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; \u6ce8\u610f\uff1a\u4ee5\u4e0a\u547d\u4ee4\u6536\u96c6\u7684\u662fproject\u76ee\u5f55\u4e0bcscope\u7f3a\u7701\u7c7b\u578b\u6587\u4ef6\u7d22\u5f15\uff0c\u6709\u65f6\u5019\u6211\u4eec\u81ea\u5b9a\u4e49\u6587\u4ef6\u4e0d\u80fd\u7d22\u5f15\uff0c\u6240\u4ee5\u6211\u4eec\u53ef\u4ee5\u7528\u5982\u4e0b\u547d\u4ee4\u66ff\u6362\u4ee5\u4e0a\u547d\u4ee4\uff1a<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; find&nbsp; .&nbsp; -name \"*.h\" -o -name \"*.cpp\" -o -name \"*.c\" &gt; cscope.file<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; cscope -bqk -i cscope.file<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 4)\u6dfb\u52a0cscope\u5e93\u5230vim<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; \u5bf9\u4e8e\u7b80\u53551\u4e2a\u6587\u4ef6\uff0c\u7528vim\u6253\u5f00\u67d0\u4e2a\u6e90\u7801\u6587\u4ef6\uff0c\u672b\u884c\u6a21\u5f0f\u4e0b\uff0c\u8f93\u5165\u201c:cs add cscope.out\"\u3002\u5bf9\u4e8e\u6574\u4e2aproject\u5de5\u7a0b\u6587\u4ef6\uff0c\u6211\u4eec\u9700\u8981\u501f\u52a9vim\u81ea\u5df1\u8bfb\u53d6\u914d\u7f6e\u6587\u4ef6\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; &nbsp; \u6211\u662f\u5728\u7528\u6237\u76ee\u5f55~\/.vim\/plugin\/\u4e0b\u653e\u7f6e\u4e86cscope_map.vim\u914d\u7f6e\u6587\u4ef6\uff0c\u540e\u9762\u4f1a\u9644\u4e0a\u3002<br \/><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; 5\uff09cscope\u5e38\u7528\u65b9\u6cd5<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; Ctrl-\\ s \u67e5\u627e\u6240\u6709\u5f53\u524d\u5149\u6807\u6240\u5728\u7b26\u53f7\u51fa\u73b0\u8fc7\u4f4d\u7f6e\u3002<br \/>&nbsp; &nbsp; &nbsp; Ctrl-\\ c \u67e5\u627e\u6240\u6709\u8c03\u7528\u5f53\u524d\u5149\u6807\u6240\u5728\u51fd\u6570\u7684\u51fd\u6570\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; &nbsp; \u5f53\u7136\u8fd8\u6709\u5176\u5b83\u6309\u952e\uff0c\u8bf7\u9605\u8bfb\u914d\u7f6e\u6587\u4ef6\u6216\u8005\u5728vim\u547d\u4ee4\u884c\u6267\u884c\uff1ahelp cscope<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u6ce8\u610f\uff1a\u901a\u8fc7\u5feb\u6377\u952e\u67e5\u627e\u67d0\u4e2a\u7b26\u53f7\u540e\uff0c\u4f1a\u7acb\u5373\u8df3\u8f6c\u5230\u7b2c\u4e00\u4e2a\u627e\u5230\u7684\u8be5\u7b26\u53f7\u51fa\u73b0\u7684\u4f4d\u7f6e\u3002\u5982\u679c\u4f60\u5bf9\u8fd9\u6b21\u9ed8\u8ba4\u8df3\u8f6c\u7684\u4f4d\u7f6e\u4e0d\u6ee1\u610f\uff0c\u5728Vim\u547d\u4ee4\u884c\u4e0b\u8fd0\u884ccw\u547d\u4ee4\uff0c\u5c31\u80fd\u5728\u7f16\u8f91\u533a\u4e0b\u9762quickfix\u7a97\u53e3\u770b\u5230\u6240\u6709\u67e5\u627e\u7ed3\u679c\u7684\u5217\u8868\uff0c\u70b9\u51fb\u76f8\u5e94\u5217\u8868\u9879\u5c31\u80fd\u8df3\u8f6c\u5230\u76f8\u5e94\u4f4d\u7f6e\u3002<br \/><\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.4&nbsp; winmanager<br \/><\/span><\/span><\/h4>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; WinManager\u7528\u4e8e\u7ba1\u7406\u6587\u4ef6\u6d4f\u89c8\u5668\u548c\u7f13\u51b2\u533a\uff08buffer\uff09\u3002<\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u5b89\u88c5\u547d\u4ee4\u4e3a\uff1avim-addons install winmanager<br \/><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u914d\u7f6e\u89c1\u9644\u5f55vimrc\uff0c\u8fdb\u5165vim\u4e4b\u540e\u6253\u5f00\u6216\u8005\u5173\u95ed\u547d\u4ee4\u662f\u8f93\u5165:WMToggle<\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.5 minibufexplorer<br \/><\/span><\/span><\/h4>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u5b89\u88c5\u547d\u4ee4\u4e3a\uff1avim-addons install minibufexplorer<br \/><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; &nbsp; \u914d\u7f6e\u89c1\u9644\u5f55vimrc<\/span><\/span><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\"><br \/><\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.6 omnicppcomplete\uff08\u81ea\u52a8\u8865\u9f50\uff09<\/span><\/span><\/h4>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; \u5b89\u88c5\u547d\u4ee4\u4e3a\uff1avim-addons install omnicppcomplete<br \/><\/span><\/span><\/p>\n<p><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">&nbsp; \u914d\u7f6e\u6587\u4ef6\u89c1\u9644\u5f55vimrc<\/span><\/span><\/p>\n<h4><span style=\"background-color: #c0c0c0\"><span style=\"background-color: #ffffff\">2.3.7 AutoComplPop\uff08\u666e\u901a\u53d8\u91cf\u548c\u51fd\u6570\u81ea\u52a8\u5f39\u51fa\u8865\u9f50\uff09<br \/><\/span><\/span><\/h4>\n<p>&nbsp; &nbsp; &nbsp; \u4e0b\u8f7d\u94fe\u63a5\uff1a<span style=\"font-size: 14px\">http:\/\/www.vim.org\/scripts\/script.php?script_id=1879&nbsp;<\/span><\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; \u5b89\u88c5\u65b9\u6cd5\uff1a<\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;\u5148\u89e3\u538b\uff1aunzip vim-autocomplpop.zip\uff0c\u5c06\u89e3\u538b\u540e\u7684\u6587\u4ef6\u62f7\u8d1d\u5230~\/.vim\/ \u4e0b\u7684\u76f8\u5e94\u76ee\u5f55\u91cc\uff1a<\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;autoload\/*&nbsp; &nbsp; -&gt;&nbsp; &nbsp; ~\/.vim\/autoload\/<\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;doc\/*&nbsp; &nbsp; -&gt;&nbsp; &nbsp; ~\/.vim\/doc\/<\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;plugin\/*&nbsp; &nbsp; -&gt;&nbsp; &nbsp; ~\/.vim\/plugin\/<\/p>\n<p>&nbsp; &nbsp; &nbsp; \u5e2e\u52a9\u4f7f\u7528\uff1a<\/p>\n<p>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \u91cd\u65b0\u6253\u5f00vim\u5373\u53ef\u4f7f\u7528\u3002\u6dfb\u52a0help\u6587\u4ef6\uff1ahelptags ~\/.vim\/doc\/\u5373\u53ef\uff08\u6253\u5f00\u5e2e\u52a9\u6587\u4ef6\uff1ahelp autocomplpop\uff09<\/p>\n<h4>2.3.8 echofunc(\u51fd\u6570\u539f\u578b\u63d0\u793a)<\/h4>\n<p>&nbsp; &nbsp; echofunc\u4e0b\u8f7d\u5730\u5740\uff1ahttp:\/\/www.vim.org\/scripts\/script.php?script_id=1735<br \/>&nbsp; &nbsp; \u4e0b\u8f7d\u5b8c\u6210\u540e\uff0c\u628aechofunc.vim\u6587\u4ef6\u653e\u5230 ~\/.vim\/plugin\u6587\u4ef6\u5939\u4e2d<br \/>&nbsp; &nbsp; \u5f53\u5728vim\u63d2\u5165(insert)\u6a21\u5f0f\u4e0b\u7d27\u63a5\u7740\u51fd\u6570\u540d\u540e\u8f93\u5165\u4e00\u4e2a\"(\"\u7684\u65f6\u5019, \u8fd9\u4e2a\u51fd\u6570\u7684\u58f0\u660e\u5c31\u4f1a\u81ea\u52a8\u663e\u793a\u5728\u4fe1\u606f\u63d0\u793a\u680f\u3002<\/p>\n<p>&nbsp; &nbsp; \u6ce8\u610f\uff1a\u8fd9\u4e2a\u63d2\u4ef6\u9700\u8981tags\u6587\u4ef6\u7684\u652f\u6301, \u5e76\u4e14\u5728\u521b\u5efatags\u6587\u4ef6\u7684\u65f6\u5019\u8981\u52a0\u9009\u9879\"--fields=+lS\"\u3002&nbsp; ctags -R --field=+IS<\/p>\n<h4>2.3.9 taglist<\/h4>\n<p>&nbsp; &nbsp; &nbsp; taglist\u7528\u4e8e\u5217\u51fa\u4e86\u5f53\u524d\u6587\u4ef6\u4e2d\u7684\u6240\u6709\u6807\u7b7e\uff08\u5b8f, \u5168\u5c40\u53d8\u91cf, \u51fd\u6570\u540d\u7b49\uff09\u3002<br \/>&nbsp; &nbsp; \u5b89\u88c5Taglist\u547d\u4ee4\uff1a vim-addons install taglist<\/p>\n<p>&nbsp; &nbsp; &nbsp; \u914d\u7f6e\u89c1\u9644\u5f55vimrc\uff0c\u8fdb\u5165vim\u4e4b\u540e\u5173\u95ed\u6216\u8005\u6253\u5f00taglist\u65b9\u6cd5\u662f\u672b\u884c\u547d\u4ee4\u6a21\u5f0f\u8f93\u5165:Taglist\u3002<\/p>\n<h4>2.3.10 quickfix<\/h4>\n<p>&nbsp; &nbsp; &nbsp; \u5728\u7a0b\u5e8f\u7684\u5f00\u53d1\u8fc7\u7a0b\u4e2d\uff0c\u5f88\u91cd\u8981\u7684\u4e00\u4e2a\u5faa\u73af\u662f:\u7f16\u8f91-\u7f16\u8bd1-\u7f16\u8f91\uff0cvim\u4e2d\u7684quickfix\u529f\u80fd\u5c31\u662f\u4e3a\u4e86\u63d0\u9ad8\u8fd9\u4e00\u5faa\u73af\u7684\u6548\u7387\u3002<\/p>\n<p>&nbsp; &nbsp; \u63a8\u8350\u4f7f\u7528Makefile\u7684\u65b9\u5f0f\u8fdb\u884c\u9879\u76ee\u7684\u7f16\u8bd1\u3001\u7ba1\u7406\uff0c\u53ef\u4ee5\u5b9e\u73b0\u9879\u76ee\u7684\u81ea\u52a8\u5316\u7ba1\u7406\u3001\u6709\u5229\u4e8e\u63d0\u9ad8\u6548\u7387\u3002\u901a\u8fc7make\u547d\u4ee4\u5b8c\u6210\u7a0b\u5e8f\u7684\u7f16\u8bd1\u5de5\u4f5c\u540e\uff0c\u4f1a\u5f97\u5230\u7f16\u8bd1\u7ed3\u679c\uff0c\u4e00\u822c\u4f1a\u6709\u4e00\u4e9b\u7f16\u8bd1\u9519\u8bef\uff0cquickfix\u529f\u80fd\u4f7f\u6211\u4eec\u53ef\u4ee5\u76f4\u63a5\u8df3\u5230\u6587\u4ef6\u4e2d\u7684\u9519\u8bef\u4f4d\u7f6e\uff0c\u76f4\u63a5\u8fdb\u884c\u4fee\u6539\uff0c\u5e76\u901a\u8fc7\u4f7f\u7528quickfix\u7684\u547d\u4ee4\u5b8c\u6210\u9519\u8bef\u5217\u8868\u7684\u8df3\u8f6c\u3002<\/p>\n<p>&nbsp; &nbsp; \u5982\u679c\u4ec5\u67091\u4e2a\u6587\u4ef6\u4e5f\u61d2\u5f97\u5199Makefile\u6587\u4ef6\uff0c\u53ef\u4ee5\u91c7\u7528\u5982\u4e0b2\u6761\u547d\u4ee4\u5904\u7406\uff1a<\/p>\n<p>  &nbsp; &nbsp; \uff1aset makeprg=gcc\\ test.c\\ -o\\ test<br \/>\n<br \/>&nbsp; &nbsp; \uff1amake   &nbsp; &nbsp; \u53d8\u91cf\u7684\u503c\u4e3a\u5b57\u7b26\u4e32\uff0c\u5f53\u5728\u5176\u4e2d\u6709\u7a7a\u683c\u65f6\u9700\u8981\u7528\\\u8fdb\u884c\u8f6c\u4e49\uff0c\u540c\u6837\u5982\u679c\u60f3\u8f93\u5165\\\u4e5f\u8981\u8fdb\u884c\u8f6c\u4e49\u3002<br \/>\n<br \/>&nbsp; &nbsp; \u6ce8\u610f\uff1a\u5728vim\u8fd0\u884c\u65f6\u901a\u8fc7\u547d\u4ee4\u884c\u8bbe\u7f6e\u7684\u53d8\u91cf\u503c\u5747\u662f\u4e34\u65f6\u7684\uff0c\u5373\u5f53\u9000\u51favim\u73af\u5883\u65f6\uff0c\u8be5\u53d8\u91cf\u503c\u4f1a\u6062\u590d\u4e3a\u914d\u7f6e\u6587\u4ef6\u4e2d\u7684\u503c\u6216\u8005\u9ed8\u8ba4\u503c\u3002<br \/>\n<br \/>&nbsp; &nbsp;<br \/>\n<br \/>&nbsp; &nbsp;  &nbsp; &nbsp; \u5e38\u7528\u7684quickfix\u547d\u4ee4\u4e3a\uff1a   &nbsp; &nbsp; :cc &nbsp; &nbsp; \u663e\u793a\u8be6\u7ec6\u9519\u8bef\u4fe1\u606f   &nbsp; &nbsp; :cp &nbsp; &nbsp; \u8df3\u5230\u4e0a\u4e00\u4e2a\u9519\u8bef   &nbsp; &nbsp; :cn &nbsp; &nbsp; \u8df3\u5230\u4e0b\u4e00\u4e2a\u9519\u8bef   &nbsp; &nbsp; :cl &nbsp; &nbsp; &nbsp;\u5217\u51fa\u6240\u6709\u9519\u8bef   &nbsp; &nbsp; :cw &nbsp; &nbsp; \u5982\u679c\u6709\u9519\u8bef\u5217\u8868\uff0c\u5219\u6253\u5f00quickfix\u7a97\u53e3\uff0c\u6ca1\u6709\u5219\u4ec0\u4e48\u4e5f\u4e0d\u9519   <\/p>\n<h2>3. \u9644\u5f55<\/h2>\n<h3>3.1 vimrc\u8bbe\u7f6e<\/h3>\n<p>&nbsp; &nbsp; \u4e0b\u9762\u662f\u6211\u7684vimrc\u914d\u7f6e\uff0c\u8fd9\u4e2a\u6587\u4ef6\u653e\u5728\u76ee\u5f55\/home\/user\/\u4e0b\u3002<\/p>\n<p><span style=\"background-color: #cccccc\">runtime! debian.vim<\/p>\n<p>\" Uncomment the next line to make Vim more Vi-compatible<br \/>\" NOTE: debian.vim sets 'nocompatible'. Setting 'compatible' changes numerous<br \/>\" options, so any other options should be set AFTER setting 'compatible'.<br \/>set nocompatible<\/p>\n<p>\" Vim5 and later versions support syntax highlighting. Uncommenting the<br \/>\" following enables syntax highlighting by default.<br \/>if has(\"syntax\")<br \/>&nbsp; &nbsp;syntax on <br \/>endif<br \/>colorscheme ron &nbsp;<\/p>\n<p>\" detect file type<br \/>filetype on<br \/>filetype plugin on<\/p>\n<p>\" If using a dark background within the editing area and syntax highlighting<br \/>\" turn on this option as well<br \/>set background=dark<\/p>\n<p>\" Uncomment the following to have Vim jump to the last position when<br \/>\" reopening a file<br \/>if has(\"autocmd\")<br \/>&nbsp; &nbsp;au BufReadPost * if line(\"'\\\"\") &gt; 1 &amp;&amp; line(\"'\\\"\") &lt;= line(\"$\") | exe \"normal! g'\\\"\" | endif<br \/>&nbsp; &nbsp;\"have Vim load indentation rules and plugins according to the detected filetype<br \/>&nbsp; &nbsp;filetype plugin indent on<br \/>endif<\/p>\n<p>\" The following are commented out as they cause vim to behave a lot<br \/>\" differently from regular Vi. They are highly recommended though.<\/p>\n<p>\"set ignorecase <br \/>\"set smartcase&nbsp; &nbsp; &nbsp; &nbsp;<br \/>set autowrite&nbsp; &nbsp; &nbsp; &nbsp;<br \/>set autoindent&nbsp; &nbsp; &nbsp; &nbsp;<br \/>\"set smartindent&nbsp; &nbsp; &nbsp;<br \/>set tabstop=4&nbsp; &nbsp; &nbsp; &nbsp;<br \/>set softtabstop=4 &nbsp;<br \/>set shiftwidth=4 &nbsp;<br \/>set cindent&nbsp; &nbsp; &nbsp;<br \/>set cinoptions={0,1s,t0,n-2,p2s,(03s,=.5s,&gt;1s,=1s,:1s&nbsp; &nbsp; &nbsp;<br \/>\"set backspace=2&nbsp; &nbsp;<br \/>set showmatch&nbsp; &nbsp; &nbsp;<br \/>set linebreak&nbsp; &nbsp; &nbsp;<br \/>set whichwrap=b,s,&lt;,&gt;,[,] <br \/>\"set hidden \" Hide buffers when they are abandoned<br \/>set mouse=a&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br \/>set number&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br \/>\"set previewwindow&nbsp; &nbsp;<br \/>set history=50&nbsp; &nbsp; &nbsp;<\/p>\n<p>set laststatus=2 <br \/>set ruler&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<\/p>\n<p>set showcmd&nbsp; &nbsp;<br \/>set showmode <\/p>\n<p>\"--find setting--<br \/>set incsearch&nbsp; &nbsp; &nbsp; &nbsp;<br \/>set hlsearch&nbsp; &nbsp;<\/p>\n<p>\"--ctags setting--<br \/>map &lt;F5&gt; :!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .&lt;CR&gt;&lt;CR&gt; :TlistUpdate&lt;CR&gt;<br \/>imap &lt;F5&gt; &lt;ESC&gt;:!ctags -R --c++-kinds=+p --fields=+iaS --extra=+q .&lt;CR&gt;&lt;CR&gt; :TlistUpdate&lt;CR&gt;<br \/>set tags=tags<br \/>set tags+=.\/tags \"add current directory's generated tags file<br \/>\"set tags+=~\/test\/tags <\/p>\n<p>\"-- omnicppcomplete setting --<br \/>imap &lt;F3&gt; &lt;C-X&gt;&lt;C-O&gt;<br \/>imap &lt;F2&gt; &lt;C-X&gt;&lt;C-I&gt;<br \/>set completeopt=menu,menuone <br \/>let OmniCpp_MayCompleteDot = 1 \" autocomplete with .<br \/>let OmniCpp_MayCompleteArrow = 1 \" autocomplete with -&gt;<br \/>let OmniCpp_MayCompleteScope = 1 \" autocomplete with ::<br \/>let OmniCpp_SelectFirstItem = 2 \" select first item (but don't insert)<br \/>let OmniCpp_NamespaceSearch = 2 \" search namespaces in this and included files<br \/>let OmniCpp_ShowPrototypeInAbbr = 1 \" show function prototype in popup window<br \/>let OmniCpp_GlobalScopeSearch=1 \" enable the global scope search<br \/>let OmniCpp_DisplayMode=1 \" Class scope completion mode: always show all members<br \/>\"let OmniCpp_DefaultNamespaces=[\"std\"]<br \/>let OmniCpp_ShowScopeInAbbr=1 \" show scope in abbreviation and remove the last column<br \/>let OmniCpp_ShowAccess=1 <\/p>\n<p>\"-- Taglist setting --<br \/>let Tlist_Ctags_Cmd='ctags' <br \/>let Tlist_Use_Right_Window=1 <br \/>let Tlist_Show_One_File=0 <br \/>let Tlist_File_Fold_Auto_Close=1 <br \/>let Tlist_Exit_OnlyWindow=1 <br \/>let Tlist_Process_File_Always=1 <br \/>let Tlist_Inc_Winwidth=0<\/p>\n<p>\"-- WinManager setting --<br \/>let g:winManagerWindowLayout='FileExplorer|TagList' <br \/>\"let g:persistentBehaviour=0 <br \/>nmap wm :WMToggle&lt;cr&gt; <\/p>\n<p>\" -- MiniBufferExplorer --<br \/>let g:miniBufExplMapWindowNavVim = 1 <br \/>let g:miniBufExplMapWindowNavArrows = 1 <br \/>let g:miniBufExplMapCTabSwitchBufs = 1 <br \/>let g:miniBufExplModSelTarget = 1&nbsp; &nbsp;<\/p>\n<p>\"--fold setting--<br \/>set foldmethod=syntax <br \/>set foldlevel=100 <br \/>set foldcolumn=5 <\/p>\n<p>\"-- QuickFix setting --<br \/>map &lt;F6&gt; :make clean&lt;CR&gt;&lt;CR&gt;&lt;CR&gt;<br \/>map &lt;F7&gt; :make&lt;CR&gt;&lt;CR&gt;&lt;CR&gt; :copen&lt;CR&gt;&lt;CR&gt;<br \/>map &lt;F8&gt; :cp&lt;CR&gt;<br \/>map &lt;F9&gt; :cn&lt;CR&gt;<br \/>imap &lt;F6&gt; &lt;ESC&gt;:make clean&lt;CR&gt;&lt;CR&gt;&lt;CR&gt;<br \/>imap &lt;F7&gt; &lt;ESC&gt;:make&lt;CR&gt;&lt;CR&gt;&lt;CR&gt; :copen&lt;CR&gt;&lt;CR&gt;<br \/>imap &lt;F8&gt; &lt;ESC&gt;:cp&lt;CR&gt;<br \/>imap &lt;F9&gt; &lt;ESC&gt;:cn&lt;CR&gt;<\/span><\/p>\n<h3>3.2 cscope\u914d\u7f6e\u6587\u4ef6<\/h3>\n<p>&nbsp; cscope\u914d\u7f6e\u6587\u4ef6\u4f4d\u4e8e\u76ee\u5f55\uff08\/home\/user\/.vim\/plugin\uff09\u540d\u53ebcscope_map.vim\uff0c\u5185\u5bb9\u4e3a<\/p>\n<p><span style=\"background-color: #cccccc\">&nbsp;\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"<br \/>\" CSCOPE settings for vim&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;<br \/>\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"<br \/>\"<br \/>\" This file contains some boilerplate settings for vim's cscope interface,<br \/>\" plus some keyboard mappings that I've found useful.<br \/>\"<br \/>\" USAGE: <br \/>\" -- vim 6:&nbsp; &nbsp; Stick this file in your ~\/.vim\/plugin directory (or in a<br \/>\"&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'plugin' directory in some other directory that is in your<br \/>\"&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; 'runtimepath'.<br \/>\"<br \/>\" -- vim 5:&nbsp; &nbsp; Stick this file somewhere and 'source cscope.vim' it from<br \/>\"&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; your ~\/.vimrc file (or cut and paste it into your .vimrc).<br \/>\"<br \/>\" NOTE: <br \/>\" These key maps use multiple keystrokes (2 or 3 keys).&nbsp; If you find that vim<br \/>\" keeps timing you out before you can complete them, try changing your timeout<br \/>\" settings, as explained below.<br \/>\"<br \/>\" Happy cscoping,<br \/>\"<br \/>\" Jason Duell&nbsp; &nbsp; &nbsp; jduell@alumni.princeton.edu&nbsp; &nbsp; 2002\/3\/7<br \/>\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"<\/p>\n<p>\" This tests to see if vim was configured with the '--enable-cscope' option<br \/>\" when it was compiled.&nbsp; If it wasn't, time to recompile vim... <br \/>if has(\"cscope\")<\/p>\n<p>&nbsp; &nbsp;set csprg=\/usr\/bin\/cscope \"\u6307\u5b9a\u7528\u6765\u6267\u884ccscope\u7684\u547d\u4ee4<\/p>\n<p>&nbsp; &nbsp; \"\"\"\"\"\"\"\"\"\"\"\"\" Standard cscope\/vim boilerplate<\/p>\n<p>&nbsp; &nbsp; \" use both cscope and ctag for 'ctrl-]', ':ta', and 'vim -t'<br \/>&nbsp; &nbsp; set cscopetag<br \/>&nbsp; &nbsp;set csto=0&nbsp; \"\u8bbe\u7f6ecstag\u547d\u4ee4\u67e5\u627e\u6b21\u5e8f\uff1a0\u5148\u627ecscope\u6570\u636e\u5e93\u518d\u627e\u6807\u7b7e\u6587\u4ef6\uff1b1\u5148\u627e\u6807\u7b7e\u6587\u4ef6\u518d\u627ecscope\u6570\u636e\u5e93\"<br \/>&nbsp; &nbsp;set cst&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; \"\u540c\u65f6\u641c\u7d22cscope\u6570\u636e\u5e93\u548c\u6807\u7b7e\u6587\u4ef6<br \/>&nbsp; &nbsp;set cscopequickfix=s-,c-,d-,i-,t-,e-&nbsp; &nbsp; \" \u4f7f\u7528QuickFix\u7a97\u53e3\u6765\u663e\u793acscope\u67e5\u627e\u7ed3\u679c<br \/>&nbsp; &nbsp;<br \/>&nbsp; &nbsp;set nocsverb<\/p>\n<p>&nbsp; &nbsp; \" add any cscope database in current directory<br \/>&nbsp; &nbsp; if filereadable(\"cscope.out\")<br \/>&nbsp; &nbsp; &nbsp; &nbsp; cs add cscope.out &nbsp;<br \/>&nbsp; &nbsp; \" else add the database pointed to by environment variable <br \/>&nbsp; &nbsp; elseif $CSCOPE_DB != \"\"<br \/>&nbsp; &nbsp; &nbsp; &nbsp; cs add $CSCOPE_DB<br \/>&nbsp; &nbsp; endif<\/p>\n<p>&nbsp; &nbsp; \" show msg when any other cscope db added<br \/>&nbsp; &nbsp;set csverb<br \/>&nbsp; \" set cscopeverbose &nbsp;<\/p>\n<p>&nbsp; &nbsp; \"\"\"\"\"\"\"\"\"\"\"\"\" My cscope\/vim key mappings<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" The following maps all invoke one of the following cscope search types:<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \"&nbsp; 's'&nbsp; symbol: find all references to the token under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'g'&nbsp; global: find global definition(s) of the token under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'c'&nbsp; calls:&nbsp; find all calls to the function name under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 't'&nbsp; text:&nbsp; find all instances of the text under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'e'&nbsp; egrep:&nbsp; egrep search for the word under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'f'&nbsp; file:&nbsp; open the filename under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'i'&nbsp; includes: find files that include the filename under cursor<br \/>&nbsp; &nbsp; \"&nbsp; 'd'&nbsp; called: find functions that function under cursor calls<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" Below are three sets of the maps: one set that just jumps to your<br \/>&nbsp; &nbsp; \" search result, one that splits the existing vim window horizontally and<br \/>&nbsp; &nbsp; \" diplays your search result in the new window, and one that does the same<br \/>&nbsp; &nbsp; \" thing, but does a vertical split instead (vim 6 only).<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" I've used CTRL-\\ and CTRL-@ as the starting keys for these maps, as it's<br \/>&nbsp; &nbsp; \" unlikely that you need their default mappings (CTRL-\\'s default use is<br \/>&nbsp; &nbsp; \" as part of CTRL-\\ CTRL-N typemap, which basically just does the same<br \/>&nbsp; &nbsp; \" thing as hitting 'escape': CTRL-@ doesn't seem to have any default use).<br \/>&nbsp; &nbsp; \" If you don't like using 'CTRL-@' or CTRL-\\, , you can change some or all<br \/>&nbsp; &nbsp; \" of these maps to use other keys.&nbsp; One likely candidate is 'CTRL-_'<br \/>&nbsp; &nbsp; \" (which also maps to CTRL-\/, which is easier to type).&nbsp; By default it is<br \/>&nbsp; &nbsp; \" used to switch between Hebrew and English keyboard mode.<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" All of the maps involving the &lt;cfile&gt; macro use '^&lt;cfile&gt;$': this is so<br \/>&nbsp; &nbsp; \" that searches over '#include &lt;time.h&gt;\" return only references to<br \/>&nbsp; &nbsp; \" 'time.h', and not 'sys\/time.h', etc. (by default cscope will return all<br \/>&nbsp; &nbsp; \" files that contain 'time.h' as part of their name).<\/p>\n<p>&nbsp; &nbsp; \" To do the first type of search, hit 'CTRL-\\', followed by one of the<br \/>&nbsp; &nbsp; \" cscope search types above (s,g,c,t,e,f,i,d).&nbsp; The result of your cscope<br \/>&nbsp; &nbsp; \" search will be displayed in the current window.&nbsp; You can use CTRL-T to<br \/>&nbsp; &nbsp; \" go back to where you were before the search. &nbsp;<br \/>&nbsp; &nbsp; \"<\/p>\n<p>&nbsp; &nbsp; nmap &lt;C-\\&gt;s :cs find s &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;g :cs find g &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;c :cs find c &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;t :cs find t &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;e :cs find e &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;f :cs find f &lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;i :cs find i ^&lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;$&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-\\&gt;d :cs find d &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<\/p>\n<p>&nbsp; &nbsp; \" Using 'CTRL-spacebar' (intepreted as CTRL-@ by vim) then a search type<br \/>&nbsp; &nbsp; \" makes the vim window split horizontally, with search result displayed in<br \/>&nbsp; &nbsp; \" the new window.<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" (Note: earlier versions of vim may not have the :scs command, but it<br \/>&nbsp; &nbsp; \" can be simulated roughly via:<br \/>&nbsp; &nbsp; \"&nbsp; &nbsp; nmap &lt;C-@&gt;s &lt;C-W&gt;&lt;C-S&gt; :cs find s &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<\/p>\n<p>&nbsp; &nbsp; nmap &lt;C-@&gt;s :scs find s &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;g :scs find g &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;c :scs find c &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;t :scs find t &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;e :scs find e &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;f :scs find f &lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;i :scs find i ^&lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;$&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;d :scs find d &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<\/p>\n<p>&nbsp; &nbsp; \" Hitting CTRL-space *twice* before the search type does a vertical <br \/>&nbsp; &nbsp; \" split instead of a horizontal one (vim 6 and up only)<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" (Note: you may wish to put a 'set splitright' in your .vimrc<br \/>&nbsp; &nbsp; \" if you prefer the new window on the right instead of the left<\/p>\n<p>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;s :vert scs find s &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;g :vert scs find g &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;c :vert scs find c &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;t :vert scs find t &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;e :vert scs find e &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;f :vert scs find f &lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;i :vert scs find i ^&lt;C-R&gt;=expand(\"&lt;cfile&gt;\")&lt;CR&gt;$&lt;CR&gt;&nbsp; &nbsp;<br \/>&nbsp; &nbsp; nmap &lt;C-@&gt;&lt;C-@&gt;d :vert scs find d &lt;C-R&gt;=expand(\"&lt;cword&gt;\")&lt;CR&gt;&lt;CR&gt;<\/p>\n<p>&nbsp; &nbsp; \"\"\"\"\"\"\"\"\"\"\"\"\" key map timeouts<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" By default Vim will only wait 1 second for each keystroke in a mapping.<br \/>&nbsp; &nbsp; \" You may find that too short with the above typemaps.&nbsp; If so, you should<br \/>&nbsp; &nbsp; \" either turn off mapping timeouts via 'notimeout'.<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \"set notimeout <br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" Or, you can keep timeouts, by uncommenting the timeoutlen line below,<br \/>&nbsp; &nbsp; \" with your own personal favorite value (in milliseconds):<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \"set timeoutlen=4000<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" Either way, since mapping timeout settings by default also set the<br \/>&nbsp; &nbsp; \" timeouts for multicharacter 'keys codes' (like &lt;F1&gt;), you should also<br \/>&nbsp; &nbsp; \" set ttimeout and ttimeoutlen: otherwise, you will experience strange<br \/>&nbsp; &nbsp; \" delays as vim waits for a keystroke after you hit ESC (it will be<br \/>&nbsp; &nbsp; \" waiting to see if the ESC is actually part of a key code like &lt;F1&gt;).<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \"set ttimeout <br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \" personally, I find a tenth of a second to work well for key code<br \/>&nbsp; &nbsp; \" timeouts. If you experience problems and have a slow terminal or network<br \/>&nbsp; &nbsp; \" connection, set it higher.&nbsp; If you don't set ttimeoutlen, the value for<br \/>&nbsp; &nbsp; \" timeoutlent (default: 1000 = 1 second, which is sluggish) is used.<br \/>&nbsp; &nbsp; \"<br \/>&nbsp; &nbsp; \"set ttimeoutlen=100<\/p>\n<p>endif<\/span><\/p>\n<h3>3.3 ctags\u548ccscope\u811a\u672c<\/h3>\n<p>&nbsp; &nbsp; \u4e3a\u65b9\u4fbf\u4f7f\u7528\uff0c\u5982\u4e0b\u5199\u5230\u4e00\u4e2a\u811a\u672c\u4e2d\uff0c\u5728\u521b\u5efa\u5de5\u7a0bproject\u4e4b\u540e\u8c03\u7528\u4e00\u4e0b\u5373\u53ef\u521b\u5efatags\u7d22\u5f15\u548ccscope\u6570\u636e\u5e93\u3002<\/p>\n<p><span style=\"background-color: #cccccc\">#!\/bin\/sh<\/p>\n<p>ctags -R --fields=+lS<\/p>\n<p>find . -name \"*.h\" -o -name \"*.c\" -o -name \"*.cpp\" &gt; cscope.files<br \/>cscope -bkq -i cscope.files<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>1.\u5e8f\u8a00 &nbsp; &nbsp; &nbsp; &nbsp; \u672c\u6587\u662f\u672c\u4eba\u5728Ubuntu 16.04\u4e0aVim [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[28],"tags":[],"class_list":["post-14250","post","type-post","status-publish","format-standard","hentry","category-ubuntu"],"_links":{"self":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/14250","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/comments?post=14250"}],"version-history":[{"count":0,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/posts\/14250\/revisions"}],"wp:attachment":[{"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/media?parent=14250"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/categories?post=14250"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/idc.net\/help\/wp-json\/wp\/v2\/tags?post=14250"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}