Vim cscope
/**********************************************************************
* Vim cscope
* 说明:
* 之前使用Vim进行代码跟踪,都是通过Vim+ctags,传言中是cscope会相对
* 更强大,更有效,所以抽点空学习一下。
*
* 2016-4-10 深圳 南山平山村 曾剑锋
*********************************************************************/ 一、参考资料:
. Editor Tips
http://elinux.org/Editor_Tips
. 在Vim中使用cscope
http://www.cnblogs.com/sunj/archive/2012/03/12/2391610.html
. The Vim/Cscope tutorial
http://cscope.sourceforge.net/cscope_vim_tutorial.html
. vi/vim使用进阶: 程序员的利器 – cscope
http://easwy.com/blog/archives/advanced-vim-skills-cscope/ 二、安装cscope
sudo apt-get install cscope 三、创建Linux kernel cscope ARM库
make ARCH=arm cscope 四、现象:
zengjf@zengjf:~/kernel$ make ARCH=arm cscope
GEN cscope
zengjf@zengjf:~/kernel$ ls cscope.*
cscope.files cscope.out cscope.out.in cscope.out.po
zengjf@zengjf:~/kernel$ 五、.vimrc配置
......
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" cscope setting
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
if has("cscope")
set csprg=/usr/bin/cscope
set csto=
set cst
set nocsverb
" add any database in current directory
if filereadable("/home/zengjf/kernel/cscope.out")
cs add /home/zengjf/kernel/cscope.out
endif
set csverb
set cscopetag
endif nmap <c-@>s :cs find s <C-R>=expand("<cword>")<CR><CR>
nmap <c-@>g :cs find g <C-R>=expand("<cword>")<CR><CR>
nmap <c-@>c :cs find c <C-R>=expand("<cword>")<CR><CR>
nmap <c-@>t :cs find t <C-R>=expand("<cword>")<CR><CR>
nmap <c-@>e :cs find e <C-R>=expand("<cword>")<CR><CR>
nmap <c-@>f :cs find f <C-R>=expand("<cfile>")<CR><CR>
nmap <c-@>i :cs find i ^<C-R>=expand("<cfile>")<CR>$<CR>
nmap <c-@>d :cs find d <C-R>=expand("<cword>")<CR><CR>
Vim cscope的更多相关文章
- vim+cscope简易教程
Cscope具有纯正的Unix血统,它最早是由贝尔实验室为PDP-11计算机开发的,后来成为商用的AT&T Unix发行版的组成部分.直到2000年4月,这个工具才由SCO公司以BSD lic ...
- 内核源码阅读vim+cscope+ctags+taglist
杜斌博客:http://blog.db89.org/kernel-source-read-vim-cscope-ctags-taglist/ 武特博客:http://edsionte.com/tech ...
- Cscope的使用(领略Vim + Cscope的强大魅力)
文章出处:http://blog.csdn.net/dengxiayehu/article/details/6330200 Cscope的使用(领略Vim + Cscope的强大魅力) 1.Cscop ...
- Vim Cscope安装与使用
问题描述: Cscope是VIM适用的工具和插件,通过Cscope可以方便的获取某个函数的定义以及被那些函数调用 问题解决: (1)Cscope安装 注: ...
- 查看源码Vim+Cscope
http://blog.csdn.net/huiguixian/article/details/7044869
- VIM+ctags+cscope用法
使用vim + cscope/ctags,就能够实现Source Insight的功能,可以很方便地查看分析源代码. 关键词: vim, cscope, ctags, tags 1. 查看vi ...
- vim深入研究
About VIM--Unix及类Unix系统文本编辑器 Vim是一个类似于Vi的著名的功能强大.高度可定制的文本编辑器,在Vi的基础上改进和增加了很多特性.VIM是纯粹的自由软件. Vim普遍被推崇 ...
- 在用的vim插件
The-NERD-tree https://github.com/vim-scripts/The-NERD-tree 在vim中也可以有目录树的,如果要打开当前文件夹下的其他文件的话也可以很方便的进 ...
- cscope使用
[[]][]再加上][一共是 4 个在段落(对于 C 来讲就是函数)间跳转的命令. 总结是:1,相同就跳到函数的开头:(如果都是左括号或者都是右括号),不同就跳到函数的结尾: { 和 } 用来 ...
随机推荐
- Oracle RAC LoadBalance
LoadBalance 就是把负载平均的分配到集群中的各个节点,从而提高整体的吞吐能力. Oracle 10g RAC 提供了两种不同的方法来分散负载: 通过Connection Balancing, ...
- spark 1.3.0下的问题
1.在spark SQL的一个test中 无论是registerAsTable还是registerTempTable 都会有问题,经过查找各种资料,采用如下的方式: val sqlCon=new or ...
- mysql_sql语句之美
无线地址及数量统计 单个用户无线登录信息统计
- C++ 关联容器详解——从内部结构到应用
关联容器不同于顺序容器的是:顺序容器底层用数组实现,为线性结构:关联容器在实现中,用到的非线性存储方式: 顺序容器是通过元素在容器中的位置顺序存储和访问元素,而关联容器是通过键(key)存储和读取元素 ...
- Android 管理Activity中的fragments
为了管理Activity中的fragments,需要使用FragmentManager,为了得到它,需要调用Activity中的getFragmentManager()方法,接下来详细介绍,感兴趣的朋 ...
- Eclipse开发Android报错Jar mismatch! Fix your dependencies
常常打开工程,发现项目并没有错,但是会有一个红X,然后就生成不了. 发现两个版本不同的android-support-v4.jar在使用 打开window-show views-problems Ja ...
- EXTJS 4.2 资料 控件之Window窗体添加html
//这里要跳转页面 var subWindow = new Ext.Window({ title: '窗口', width: width, height: height, modal: true,// ...
- BZOJ 1588 营业额统计 Splay
主要操作为Splay中插入节点,查找前驱和后继节点. 1: #include <cstdio> 2: #include <iostream> 3: #include <c ...
- 文件/图片,批量上传【神器】--WebUploader
<system.web> <httpRuntime maxRequestLength="102400" executionTimeout="720&qu ...
- 基于Ogre的DeferredShading(延迟渲染)的实现以及应用
http://blog.sina.com.cn/s/blog_458f871201017i06.html 这篇文章写的不错,从比较宏观的角度说了下作者在OGRE中实现的延迟渲染