diff options
author | Max Christian Pohle | 2018-10-22 00:02:58 +0200 |
---|---|---|
committer | Max Christian Pohle | 2018-10-22 20:42:25 +0200 |
commit | f2e01d7e513067ddb57c75f6e38cdcf434946cf8 (patch) | |
tree | 4e8448506756d2144db173d01385798840507133 /plugin/cscope.vim | |
parent | 31f80d9c334e38e486545407ea5eb5f5cbb2f07d (diff) | |
download | vim-karlmarks-f2e01d7e513067ddb57c75f6e38cdcf434946cf8.tar.bz2 vim-karlmarks-f2e01d7e513067ddb57c75f6e38cdcf434946cf8.zip |
Major refactoring for version 2.0
vim-plug has been removed and replaced with Vims internal bundle
mechanism. But I already noticed, that there is also GLVM now and
started trying that as well.
Diffstat (limited to 'plugin/cscope.vim')
-rw-r--r-- | plugin/cscope.vim | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/plugin/cscope.vim b/plugin/cscope.vim new file mode 100644 index 0000000..b9ca444 --- /dev/null +++ b/plugin/cscope.vim | |||
@@ -0,0 +1,57 @@ | |||
1 | "======================================================================================================================= | ||
2 | " CSCOPE: http://vim.wikia.com/wiki/Cscope | ||
3 | "======================================================================================================================= | ||
4 | |||
5 | augroup MAX_CSCOPE | ||
6 | if has('cscope') " compiled with cscope support? | ||
7 | set cscopetag " CTRL-] uses cscope first, then ctags | ||
8 | set cscopeverbose | ||
9 | |||
10 | if has('quickfix') | ||
11 | set cscopequickfix=s+,c+,d+,i+,t+,e+ | ||
12 | endif | ||
13 | |||
14 | if has('menu') | ||
15 | 1001menu &Cscope.find.c\ symbol | ||
16 | \<tab>s | ||
17 | \ :cscope find s <cword><:cR> | ||
18 | 1001menu &Cscope.find.definition | ||
19 | \<tab>g | ||
20 | \ :cscope find g <cword><:cR> | ||
21 | 1001menu &Cscope.find.functions\ called\ by\ this | ||
22 | \<tab>d | ||
23 | \ :cscope find d <cword><:cR> | ||
24 | 1001menu &Cscope.find.functions\ calling\ this | ||
25 | \<tab>c | ||
26 | \ :cscope find c <cword><:cR> | ||
27 | 1001menu &Cscope.find.text\ string | ||
28 | \<tab>t | ||
29 | \ :cscope find t <cword><:cR> | ||
30 | 1001menu &Cscope.find.egrep\ pattern | ||
31 | \<tab>e | ||
32 | \ :cscope find e <cword><:cR> | ||
33 | 1001menu &Cscope.find.this\ file | ||
34 | \<tab>f | ||
35 | \ :cscope find f <cword><:cR> | ||
36 | 1001menu &Cscope.find.files\ including\ this\ file | ||
37 | \<tab>i | ||
38 | \ :cscope find i <cword><:cR> | ||
39 | 1001menu &Cscope.find.places\ where\ this\ symbol\ is\ assigned\ a\ value | ||
40 | \<tab>a | ||
41 | \ :cscope find a <cword><:cR> | ||
42 | 1001menu &Cscope.-Sep1- | ||
43 | \ : | ||
44 | 1001menu &Cscope.create\ and\ add\ database | ||
45 | \ :cscope kill -1<CR>:execute '!find -type f -regex ".*\.\(c\\|h\\|cpp\\|cxx\\|hh\\|hpp\\|hxx\)$" <bar> cscope -i- -b -q -v'<CR>:cscope add .<CR> | ||
46 | 1001menu &Cscope.-Sep2- | ||
47 | \ : | ||
48 | 1001menu &Cscope.add\ \. | ||
49 | \ :cscope add .<CR> | ||
50 | 1001menu &Cscope.show | ||
51 | \ :cscope show<CR> | ||
52 | 1001menu &Cscope.reset | ||
53 | \ :cscope reset<CR> | ||
54 | endif | ||
55 | endif | ||
56 | augroup END " MAX_CSCOPE | ||
57 | |||