-
Notifications
You must be signed in to change notification settings - Fork 0
/
.vimrc
264 lines (225 loc) · 3.72 KB
/
.vimrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
" File: .vimrc
" Author: Oleg Mokhov (mokhov)
" Thanks2: Georgiy Mostolovitsa (gfranco), Igor Spisivtsev (garris), Vyacheslav Oliyanchuk (miripiruni)
" Last Modified: 31.01.2012
" Common
set nocompatible
set autoread
set backup
set backupdir=/tmp
set directory=/tmp
" Editor
set nowrap
set undolevels=100
set backspace=indent,eol,start whichwrap+=<,>,[,]
set softtabstop=4
set shiftwidth=4
set tabstop=4
set expandtab
set smarttab
set ignorecase
set hlsearch
set incsearch
set showmatch
set smartcase
set autoindent
set smartindent
set pastetoggle=<C-v>
set nofoldenable
set splitright
set splitbelow
" UI
set relativenumber
set foldcolumn=0
set showtabline=0
set laststatus=2
set statusline=%t%M%R\ %P
set scrolljump=7
set novisualbell " выключаем бибиканье и мигание
set t_vb=
set wildmenu
" Keyboard
map <C-w>v :vertical wincmd f<CR>
imap <C-_> <C-X>/
let mapleader=","
" Encoding
set encoding=utf-8
set termencoding=utf-8
set fileencodings=utf-8,cp1251,koi8-r
so ~/.vim/vundle.module.vim
so ~/.vim/colors.module.vim
filetype plugin indent on
" Plugins
let g:indent_guides_guide_size=1
" let g:tagbar_ctags_bin="/Users/gfranco/.local/bin/ctags"
au BufNewFile,BufRead *.bemhtml set filetype=javascript
au BufNewFile,BufRead *.scss set filetype=css
" Remember last location in file
if has("autocmd")
au BufReadPost * if line("'\"") > 0 && line("'\"") <= line("$")
\| exe "normal g'\"" | endif
endif
" DEMO!!11
" F7 opens documentation for function under cursor
function! BrowseDoc()
if b:current_syntax == "php"
! open http://ch2.php.net/manual-lookup.php?pattern=<cword>
elseif b:current_syntax == "perl"
! open http://perldoc.perl.org/search.html?q=<cword>
elseif b:current_syntax == "cpp"
let cname = tolower(cword);
! open file:///opt/qt-4.3.4/doc/html/<cname>
else
echo "Hello"
endif
endfunction
map <F7> :call BrowseDoc()
let g:Powerline_symbols="fancy"
let g:Powerline_cache_file=$HOME . "/.vim/Powerline.cache"
" Don't use the terminal's horrible secondary screen
" set t_ti= t_te=
"
set cursorline
" Don't copy text, replaced by pasted
vmap p "_dp
vmap P "_dP
let delimitMate_expand_cr = 1
set backspace=indent,eol,start
map <C-l> <C-w>l
map <C-h> <C-w>h
map <C-j> <C-w>j
map <C-k> <C-w>k
map <C-a> :%s/\s\+$//g<CR>
map —ë `
map –π q
map —Ü w
map —É e
map –∫ r
map –µ t
map –Ω y
map –≥ u
map —à i
map —â o
map –∑ p
map —Ö [
map —ä ]
map —Ñ a
map —ã s
map –≤ d
map –∞ f
map –ø g
map —Ä h
map –æ j
map –ª k
map –¥ l
map –∂ ;
map —ç '
map —è z
map —á x
map —Å c
map –º v
map –∏ b
map —Ç n
map —å m
map –± ,
map —é .
map –Å ~
map –ô Q
map –¶ W
map –£ E
map –ö R
map –ï T
map –ù Y
map –ì U
map –® I
map –© O
map –ó P
map –• {
map –™ }
map –§ A
map –´ S
map –í D
map –ê F
map –ü G
map –† H
map –û J
map –õ K
map –î L
map –ñ :
map –≠ "
map –Ø Z
map –ß X
map –° C
map –ú V
map –ò B
map –¢ N
map –¨ M
map –ë <
map –Æ >
map ё `
map й q
map ц w
map у e
map к r
map е t
map н y
map г u
map ш i
map щ o
map з p
map х [
map ъ ]
map ф a
map ы s
map в d
map а f
map п g
map р h
map о j
map л k
map д l
map ж ;
map э '
map я z
map ч x
map с c
map м v
map и b
map т n
map ь m
map б ,
map ю .
map Ё ~
map Й Q
map Ц W
map У E
map К R
map Е T
map Н Y
map Г U
map Ш I
map Щ O
map З P
map Х {
map Ъ }
map Ф A
map Ы S
map В D
map А F
map П G
map Р H
map О J
map Л K
map Д L
map Ж :
map Э "
map Я Z
map Ч X
map С C
map М V
map И B
map Т N
map Ь M
map Б <
map Ю >
set wildignore+=*/.git/*,*/.hg/*,*/.svn/*