-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.vimrc
163 lines (128 loc) · 3.84 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
" be iMproved, required
set nocompatible
" required
filetype off
" shorten load message
set shm=a
set showcmd
set undofile udir=$HOME/share/vimundo ul=1000 ur=10000
set rtp+=~/.vim/bundle/Vundle.vim
let onNewRead='au BufNewFile,BufRead'
let onNewReadEnter=onNewRead . ',BufEnter'
" Location of configuration scripts by category
" Participates in file discovery for relative paths
rviminfo! ~/.vim/plugin/rcfiles/
" Functions, mainly for bindings
runtime! functions.vim
" Plugin and native value settings
runtime! params.vim
" Keyboard bindings
runtime! bindings.vim
" Testing symlink
runtime! linked.vim
set list lcs=tab:░\ "
set backspace=indent,eol,start
set encoding=utf8
set ttym=xterm2 mouse=a
set t_Co=256
set nu ru cuc cul sbr=`-
set cole=2 cocu=vin
set cot=menu cot-=preview
set ph=20
set diffopt=filler
set nofixendofline
call vundle#begin()
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
Plugin 'scrooloose/nerdtree'
" Plugin 'terryma/vim-multiple-cursors'
Plugin 'tmux-plugins/vim-tmux'
Plugin 'bling/vim-bufferline'
Plugin 'vim-airline/vim-airline'
Plugin 'vim-airline/vim-airline-themes'
Plugin 'edkolev/tmuxline.vim'
"let g:airline#extensions#tmuxline#enabled=0
let g:tmuxline_theme = {
\ 'a' : [ 28, 231 ],
\ 'b' : [ 65, 231 ],
\ 'c' : [ 102, 231 ],
\ 'x' : [ 139, 232 ],
\ 'y' : [ 176, 232 ],
\ 'z' : [ 213, 232 ],
\ 'win' : [ 103, 236 ],
\ 'cwin' : [ 236, 103 ],
\ 'bg' : [ 244, 236 ],
\ }
Plugin 'jonathanfilip/vim-lucius'
" Plugin 'luochen1990/rainbow'
" let g:rainbow_active = 1
Plugin 'shawncplus/phpcomplete.vim'
Plugin 'beyondmarc/opengl.vim'
Plugin 'vim-scripts/gtk-vim-syntax'
Plugin 'tikhomirov/vim-glsl'
Plugin 'kana/vim-operator-user'
Plugin 'rhysd/vim-clang-format'
Plugin 'Rip-Rip/clang_complete'
"Plugin 'octol/vim-cpp-enhanced-highlight'
Plugin 'bfrg/vim-cpp-modern'
syntax enable
syn sync fromstart
au CursorMovedI * if pumvisible() == 0|pclose|endif
au InsertLeave * if pumvisible() == 0|pclose|endif
" Resume; restore cursor position and center on screen
au BufReadPost * if line("'\"") > 1
\ && line("'\"") <= line("$")
\ | exe "normal! g'\"ztzz"
" | exe 'normal! zz' | endif
exec onNewRead . ' {.,}tmux*.conf set filetype=tmux | compiler tmux'
exec onNewRead . ' *.txt,*.warprc set filetype=txt'
exec onNewRead . ' *.vim,*.vimrc set filetype=vim'
exec onNewRead . ' *.cpp,*.tpp,*.hpp set'
\ . ' filetype=cpp omnifunc=omni#cpp#complete#Main'
\ . ' completefunc=ClangComplete'
exec onNewRead . ' *.mk,Makefile set filetype=make'
au BufAdd,BufNew,BufCreate,BufEnter,BufRead *.tpp set filetype=cpp
au BufAdd,BufNew,BufCreate,BufEnter,BufRead *.glsl set ft=glsl
" required
call vundle#end()
filetype plugin indent on
function! BufferCount()
return len(getbufinfo({'buflisted':1}))
endfunction
function! CloseOrQuit()
try
if BufferCount() > 1
silent bdelete
else
silent quit
endif
catch
echo "Could not close or quit."
endtry
endfunction
" command DiffOrig vert new | set bt=nofile | r # | 0d_ | diffthis
" \ | wincmd p | diffthis
" nmap <Leader>d :DiffOrig<CR>
" Themes, colors, icons
set ls=0
set stal=1
" Decorations
" Plugin 'airblade/vim-gitgutter'
" Whitespace visualization
Plugin 'Yggdroot/indentLine'
Plugin 'ntpeters/vim-better-whitespace'
" Plugin 'nathanaelkane/vim-indent-guides'
" Plugin 'jeetsukumaran/vim-indentwise'
Plugin 'DoxygenToolkit.vim'
Plugin 'CompleteHelper'
colorscheme lucius
LuciusBlack
" RO plugins
" Plugin 'jez/vim-superman'
" Language support
" Plugin 'bash-support.vim'
exec onNewRead . ' * :set tw=100 cc=+1'
" tm/ttm control serial keypress reaction time (interruption vs. latency)
" - Escape timeout is for a special case of this more general tradeoff
" set tm=500 ttm=5 cc=+1 noet nosi noai noci nocin nopi sts=0 sw=4 ts=4
set tm=500 ttm=5 cc=+1 noet noai si noci nocin nopi sts=0 sw=4 ts=4