-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.vimrc
More file actions
194 lines (161 loc) · 4.97 KB
/
.vimrc
File metadata and controls
194 lines (161 loc) · 4.97 KB
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
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
Plugin 'tmhedberg/SimpylFold'
Plugin 'Konfekt/FastFold'
Plugin 'python-mode/python-mode'
Plugin 'davidhalter/jedi-vim'
Plugin 'fatih/vim-go'
Plugin 'altercation/vim-colors-solarized'
Plugin 'sjbach/lusty'
Plugin 'tpope/vim-surround'
Plugin 'ctrlpvim/ctrlp.vim'
Plugin 'terryma/vim-multiple-cursors'
"Plugin 'powerline/powerline'
Plugin 'vim-airline/vim-airline'
Plugin 'vim-airline/vim-airline-themes'
Plugin 'Shougo/neocomplete'
Plugin 'scrooloose/nerdtree'
Plugin 'jeffkreeftmeijer/vim-numbertoggle'
Plugin 'xolox/vim-misc'
Plugin 'xolox/vim-session'
Plugin 'tpope/vim-fugitive'
Plugin 'tpope/vim-rhubarb'
Plugin 'easymotion/vim-easymotion'
Plugin 'exu/pgsql.vim'
" PYTHON PLUGINS
" Plugin 'Valloric/YouCompleteMe'
" Plugin 'vim-syntastic/syntastic'
" Plugin 'nvie/vim-flake8'
" let python_highlight_all=1
let NERDTreeIgnore=['\.pyc$', '\~$'] "ignore files in NERDTree
" let g:syntastic_python_flake8_exec = 'python3'
" let g:syntastic_python_flake8_args = ['-m', 'flake8']
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" :PluginList - lists configured plugins
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal
"
" see :h vundle for more details or wiki for FAQ
" Put your non-Plugin stuff after this line
" Autowrite
set autowrite
" Enable folding
set foldmethod=indent
set foldlevel=99
nnoremap <space> za
" Fix typos
cabbrev W write
cabbrev Q quit
" -- Display
set title "Update title of terminal window
set number "Display line numbers
set ruler "Display cursor position
set wrap "Wrap too long lines
set scrolloff=3 "Display at least 3 lines around your cursor
set guioptions=T "Enable toolbar
" -- Search
set ignorecase "Ignore case when searching
set smartcase "If there is an uppercase in your search term
"search case sensitive again
set incsearch "Highlight search results when typing
set hlsearch "Highlight search results
" -- Beep
set visualbell " Prevent Vim from beeping
set noerrorbells " Idem
" Backspace behaves as expected
set backspace=indent,eol,start
" Hide buffer (file) instead of abandoning when switching
" to another buffer
set hidden
syntax enable
"Enable file specific behavior like syntax highlighting and indentation
filetype on
filetype indent on
filetype plugin on
" Color theme (Solarized Dark)
"let g:solarized_visibility = "high"
"let g:solarized_contrast = "normal"
let g:solarized_termcolors = 256
let g:solarized_termtrans = 1
set background=dark
colorscheme solarized
" Font settings
set guifont=Monaco:h13
set antialias
" NERDTree auto open
" autocmd vimenter * NERDTree
" REMAPS
""split navigations
nnoremap <C-J> <C-W><C-J>
nnoremap <C-K> <C-W><C-K>
nnoremap <C-L> <C-W><C-L>
nnoremap <C-H> <C-W><C-H>
"" nerdtree toggle
nnoremap <C-T> :NERDTreeToggle<CR>
"" vim-go
map <C-n> :cnext<CR>
map <C-p> :cprevious<CR>
nnoremap <leader>a :cclose<CR>
"" Disable arrow keys
map <up> <nop>
map <down> <nop>
map <left> <nop>
map <right> <nop>
imap <up> <nop>
imap <down> <nop>
imap <left> <nop>
imap <right> <nop>
let mapleader = ","
" vim-go
let g:go_list_type = "quickfix"
autocmd BufNewFile,BufRead *.go setlocal noexpandtab tabstop=4 shiftwidth=4
" Status line settings
set laststatus=2
set showtabline=2
let g:airline#extensions#tabline#enabled = 1
" vim-session
let g:session_autoload = 'no'
let g:session_autosave = 'no'
nnoremap <leader>so :OpenSession
nnoremap <leader>ss :SaveSession
nnoremap <leader>sd :DeleteSession
nnoremap <leader>sc :CloseSession
" python-mode
let g:pymode_options_max_line_length = 100
let g:pymode_lint_options_pylint =
\ {'max-line-length': g:pymode_options_max_line_length}
let g:pymode_python = 'python3'
" let g:pymode_rope_lookup_project = 0 " This is a test...for slowness
" let g:pymode_rope = 1
" let g:pymode_lint_checkers = ['pyflakes', 'pep8']
" let g:pymode_lint_on_fly = 1
" easymotion
"" <Leader>f{char} to move to {char}
map <Leader>f <Plug>(easymotion-bd-f)
nmap <Leader>f <Plug>(easymotion-overwin-f)
"" s{char}{char} to move to {char}{char}
nmap <Leader>s <Plug>(easymotion-overwin-f2)
"" Move to line
map <Leader>L <Plug>(easymotion-bd-jk)
nmap <Leader>L <Plug>(easymotion-overwin-line)
" Move to word
map <Leader>w <Plug>(easymotion-bd-w)
nmap <Leader>w <Plug>(easymotion-overwin-w)
map / <Plug>(easymotion-sn)
omap / <Plug>(easymotion-tn)
" SQL
let g:sql_type_default = 'pgsql'