博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
我的vimrc
阅读量:6060 次
发布时间:2019-06-20

本文共 3058 字,大约阅读时间需要 10 分钟。

现在公司服务器上用的vimrc. 脚本最后几个插件几乎没怎么用到, 实际上熟读Practical Vim Edit Text at the Speed of Thought后除了ctags和cscope基本不需要其它插件. 将don't repeat yourself贯彻始终才是关键.

1 "vim set  2 "colorscheme elflord   3 colorscheme evening   4 "colorscheme molokai   5 "let g:molokai_original=1   6 "let g:rehash256=1   7 set guifont=Monospace\ 12   8 "file type   9 filetype on  10 filetype plugin on  11 "editing set  12 set nu  13 set ruler  14 set showcmd  15 "search  16 set incsearch  17 set hlsearch  18 set wrapscan  19 "syntax  20 syntax enable  21 syntax on  22 "indent  23 filetype indent on  24 set tabstop=4  25 "set expandtab  26 set shiftwidth=4  27 set formatoptions=tcrqn  28 set autoindent  29 set cindent  30 "encoding set  31 set encoding=utf-8  32 set fileencodings=ucs-bom,utf-8,cp936  33 set fileencoding=gb2312  34 set termencoding=utf-8  35 "if use ; as mapleader move with ; in normal mode will be much slower  36 "
37 "let mapleader="\" 38 "map * / # 39 xnoremap * :
call
VSetSearch()
/
=@/
40 xnoremap # :
call
VSetSearch()
?
=@/
41 function! s:VSetSearch() 42         let temp = @s 43         norm! gv"sy 44         let @/ = '\V' . substitute(escape(@s, '/\'), '\n', '\\n', 'g') 45         let @s = temp 46 endfunction 47 "add cmd :Qargs 48 command! -nargs=0 -bar Qargs execute 'args' QuickfixFilenames() 49 function! QuickfixFilenames() 50         let buffer_numbers = {} 51         for quickfix_item in getqflist() 52                 let buffer_numbers[quickfix_item['bufnr']] = bufname(quickfix_item['bufnr']) 53         endfor 54         return join(map(values(buffer_numbers), 'fnameescape(v:val)')) 55 endfunction 56 "remap curosr move key in insert mode 57 imap
58 imap
59 cnoremap
60 cnoremap
61 cnoremap
%% getcmdtype() == ':'   expand('%:h').'/' : '%%' 62 "cscope 63 map
a :cs add ./cscope.out ./
64 nmap
c :cs find c
=expand("
")
65 nmap
d :cs find g
=expand("
")
66 nmap
i :cs find i
=expand("
")
67 nmap
f :cs find f
=expand("
")
68 nmap
s :cs find s
=expand("
")
69 "minibufexplorer 70 let g:miniBufExplMapCTabSwitchBufs = 1 71 "damn secureCRT block
so remap another key here 72 nmap
73 nmap
74 "other option not use for now 75 "let g:miniBufExplMapWindowNavVim = 1 76 "let g:miniBufExplMapWindowNavArrows = 1 77 "let g:miniBufExplModSelTarget = 1 78 "grep.vim 79 let Grep_Default_Options = '-rin' 80 let Grep_Default_Filelist = './' 81 let Grep_Skip_Files = '*.o *.dep' 82 "pathogen 83 call pathogen#infect() 84 call pathogen#helptags() 85 "A.vim 86 nmap
q :A!
87 nmap
w :AV!
88 nmap
e :AS!
89 "NERDTree 90 nmap
1 :NERDTreeToggle
91 let g:NERDTreeWinPos="left" 92 let g:NERDTreeWinSize=30 93 let g:NERDTreeShowLineNumber=1 94 let g:neocomplcache_enable_at_startup=1 95 "Syntastic 96 "set statusline+=%#warningmsg# 97 "set statusline+=%{SyntasticStatuslineFlag()} 98 "set statusline+=%* 99 "let g:syntastic_always_populate_loc_list = 1 100 "let g:syntastic_auto_loc_list = 1 101 "let g:syntastic_check_on_open = 1 102 "let g:syntastic_check_on_wq = 0 103  

 

转载于:https://www.cnblogs.com/Five100Miles/p/8459118.html

你可能感兴趣的文章
七周五次课(1月26日)
查看>>
Linux系统一些系统查看指令
查看>>
vsftp虚拟用户通过pam和mysql认证
查看>>
php中的短标签 太坑人了
查看>>
[译] 可维护的 ETL:使管道更容易支持和扩展的技巧
查看>>
### 继承 ###
查看>>
单链表的逆序
查看>>
数组扩展方法之求和
查看>>
astah-professional-7_2_0安装
查看>>
函数是对象-有属性有方法
查看>>
uva 10107 - What is the Median?
查看>>
【学】SoapExtension 学习
查看>>
Java_6 方法
查看>>
Linux下基本栈溢出攻击【转】
查看>>
js -- 全局变量
查看>>
Python 无限循环
查看>>
hibernate知识点理解
查看>>
c# 连等算式都在做什么
查看>>
使用c:forEach 控制5个换行
查看>>
java web轻量级开发面试教程摘录,java web面试技巧汇总,如何准备Spring MVC方面的面试...
查看>>