diff options
author | Yigit Sever | 2019-04-10 10:52:23 +0300 |
---|---|---|
committer | Yigit Sever | 2019-04-10 10:52:23 +0300 |
commit | 6e15ee0798d53f4dc3029f14fbc36994433b8944 (patch) | |
tree | b31023a97a93a574c5e1ff50a8d0a815a925bc1c /.config/nvim | |
parent | d5a9f4c5ed15257f2590c51873b022f35009ff22 (diff) | |
download | dotfiles-6e15ee0798d53f4dc3029f14fbc36994433b8944.tar.gz dotfiles-6e15ee0798d53f4dc3029f14fbc36994433b8944.tar.bz2 dotfiles-6e15ee0798d53f4dc3029f14fbc36994433b8944.zip |
Weekly vimrc update
- colored brackets are back
- vimtex bug is fixed
- ledger file adjustments
Diffstat (limited to '.config/nvim')
-rwxr-xr-x | .config/nvim/init.vim | 35 |
1 files changed, 9 insertions, 26 deletions
diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim index 5d415ce..f3ce6d5 100755 --- a/.config/nvim/init.vim +++ b/.config/nvim/init.vim | |||
@@ -12,6 +12,8 @@ Plug 'ludovicchabant/vim-gutentags' | |||
12 | Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' | 12 | Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' |
13 | "autopair plugin | 13 | "autopair plugin |
14 | Plug 'tmsvg/pear-tree' | 14 | Plug 'tmsvg/pear-tree' |
15 | "colored brackets | ||
16 | Plug 'luochen1990/rainbow' | ||
15 | 17 | ||
16 | " Plugin outside ~/.vim/plugged with post-update hook | 18 | " Plugin outside ~/.vim/plugged with post-update hook |
17 | Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } | 19 | Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } |
@@ -88,7 +90,6 @@ call plug#end() " required | |||
88 | "}}} | 90 | "}}} |
89 | 91 | ||
90 | "{{{Auto Commands | 92 | "{{{Auto Commands |
91 | |||
92 | " Automatically cd into the directory that the file is in | 93 | " Automatically cd into the directory that the file is in |
93 | autocmd BufEnter * silent! lcd %:p:h | 94 | autocmd BufEnter * silent! lcd %:p:h |
94 | 95 | ||
@@ -97,11 +98,9 @@ autocmd BufRead,BufWrite * if ! &bin | silent! %s/\s\+$//ge | endif | |||
97 | 98 | ||
98 | " Close vim if the only window left open is NERDTree | 99 | " Close vim if the only window left open is NERDTree |
99 | autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif | 100 | autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif |
100 | |||
101 | "}}} | 101 | "}}} |
102 | 102 | ||
103 | "{{{Misc Settings | 103 | "{{{Misc Settings |
104 | |||
105 | let g:ycm_global_ycm_extra_conf = '~/.ycm_extra_conf.py' | 104 | let g:ycm_global_ycm_extra_conf = '~/.ycm_extra_conf.py' |
106 | 105 | ||
107 | " Tab stuff | 106 | " Tab stuff |
@@ -120,7 +119,6 @@ set scrolloff=4 " Keep n lines above/below cursor | |||
120 | set mouse=c | 119 | set mouse=c |
121 | set number " line numbers | 120 | set number " line numbers |
122 | set foldmethod=marker " folding stuffs | 121 | set foldmethod=marker " folding stuffs |
123 | set nohidden " when i close a tab, remove the buffer | ||
124 | set title " set terminal title | 122 | set title " set terminal title |
125 | set showmatch " jump to the matching bracket briefly, REMOVE AFTER TESTING | 123 | set showmatch " jump to the matching bracket briefly, REMOVE AFTER TESTING |
126 | set linebreak " wrap using 'breakat' character | 124 | set linebreak " wrap using 'breakat' character |
@@ -135,11 +133,9 @@ set smartcase | |||
135 | " https://stackoverflow.com/a/3445040/ | 133 | " https://stackoverflow.com/a/3445040/ |
136 | " switch case labels | 134 | " switch case labels |
137 | set cinoptions=l1 | 135 | set cinoptions=l1 |
138 | |||
139 | " }}} | 136 | " }}} |
140 | 137 | ||
141 | "{{{Look and Feel | 138 | "{{{Look and Feel |
142 | |||
143 | set termguicolors | 139 | set termguicolors |
144 | "highlight NormalNC guibg='Black' | 140 | "highlight NormalNC guibg='Black' |
145 | 141 | ||
@@ -149,7 +145,6 @@ let g:nord_italic_comments = 1 | |||
149 | let g:nord_cursor_line_number_background = 1 | 145 | let g:nord_cursor_line_number_background = 1 |
150 | 146 | ||
151 | colorscheme nord | 147 | colorscheme nord |
152 | |||
153 | " }}} | 148 | " }}} |
154 | 149 | ||
155 | "{{{ Functions | 150 | "{{{ Functions |
@@ -186,7 +181,6 @@ endfunction | |||
186 | "}}} | 181 | "}}} |
187 | 182 | ||
188 | "{{{ Mappings | 183 | "{{{ Mappings |
189 | |||
190 | " Open Url on this line with the browser \w | 184 | " Open Url on this line with the browser \w |
191 | map <Leader>w :call Browser ()<CR> | 185 | map <Leader>w :call Browser ()<CR> |
192 | " Open the TagBar Plugin <F3> | 186 | " Open the TagBar Plugin <F3> |
@@ -233,39 +227,29 @@ nnoremap <Leader>t "=strftime("%F")<CR>P | |||
233 | "}}} | 227 | "}}} |
234 | 228 | ||
235 | "{{{Tagbar | 229 | "{{{Tagbar |
236 | |||
237 | let g:tagbar_autofocus = 1 | 230 | let g:tagbar_autofocus = 1 |
238 | let g:tagbar_compact = 1 | 231 | let g:tagbar_compact = 1 |
239 | let g:tagbar_sort = 0 | 232 | let g:tagbar_sort = 0 |
240 | let g:tagbar_width = 25 | 233 | let g:tagbar_width = 25 |
241 | |||
242 | "}}} | 234 | "}}} |
243 | 235 | ||
244 | "{{{ Airline | 236 | "{{{ Airline |
245 | 237 | let g:airline_powerline_fonts = 1 | |
246 | let g:airline_powerline_fonts = 1 " fira code | ||
247 | 238 | ||
248 | let g:airline#extensions#tabline#formatter = 'unique_tail' | 239 | let g:airline#extensions#tabline#formatter = 'unique_tail' |
249 | let g:airline#extensions#ycm#enabled = 1 | 240 | let g:airline#extensions#ycm#enabled = 1 |
250 | |||
251 | "}}} | 241 | "}}} |
252 | 242 | ||
253 | "{{{ NERDTree | 243 | "{{{ NERDTree |
254 | |||
255 | let g:NERDTreeWinSize=25 | 244 | let g:NERDTreeWinSize=25 |
256 | |||
257 | "}}} | 245 | "}}} |
258 | 246 | ||
259 | "{{{ Ale | 247 | "{{{ Ale |
260 | |||
261 | let g:ale_sign_error = '✗' | 248 | let g:ale_sign_error = '✗' |
262 | let g:ale_sign_warning = '⚑' | 249 | let g:ale_sign_warning = '⚑' |
263 | |||
264 | "}}} | 250 | "}}} |
265 | 251 | ||
266 | "{{{ YouCompleteMe | 252 | "{{{ YouCompleteMe |
267 | |||
268 | "let g:ycm_autoclose_preview_window_after_completion = 1 | ||
269 | let g:ycm_always_populate_location_list = 1 | 253 | let g:ycm_always_populate_location_list = 1 |
270 | let g:ycm_error_symbol = '✗' | 254 | let g:ycm_error_symbol = '✗' |
271 | let g:ycm_warning_symbol = '⚑' | 255 | let g:ycm_warning_symbol = '⚑' |
@@ -294,11 +278,11 @@ let g:ycm_filetype_specific_completion_to_disable = { | |||
294 | "}}} | 278 | "}}} |
295 | 279 | ||
296 | "{{{ Ledger | 280 | "{{{ Ledger |
297 | |||
298 | let g:ledger_extra_options = '--pedantic --explicit --check-payees' | 281 | let g:ledger_extra_options = '--pedantic --explicit --check-payees' |
299 | au FileType ledger noremap { ?^\d<CR> | 282 | au FileType ledger noremap { ?^\d<CR> |
300 | au FileType ledger noremap } /^\d<CR> | 283 | au FileType ledger noremap } /^\d<CR> |
301 | 284 | let g:ledger_maxwidth = 48 | |
285 | let g:ledger_fillstring = ' ~' | ||
302 | "}}} | 286 | "}}} |
303 | 287 | ||
304 | "{{{ UltiSnips/YouCompleteMe | 288 | "{{{ UltiSnips/YouCompleteMe |
@@ -318,7 +302,6 @@ let g:UltiSnipsListSnippets = "<C-h>" | |||
318 | "}}} | 302 | "}}} |
319 | 303 | ||
320 | "{{{ vim-startify | 304 | "{{{ vim-startify |
321 | |||
322 | function! StartifyEntryFormat() | 305 | function! StartifyEntryFormat() |
323 | return 'WebDevIconsGetFileTypeSymbol(absolute_path) ." ". entry_path' | 306 | return 'WebDevIconsGetFileTypeSymbol(absolute_path) ." ". entry_path' |
324 | endfunction | 307 | endfunction |
@@ -331,8 +314,6 @@ else | |||
331 | let entry_format .= '. entry_path' | 314 | let entry_format .= '. entry_path' |
332 | endif | 315 | endif |
333 | 316 | ||
334 | |||
335 | |||
336 | let g:ascii = [ | 317 | let g:ascii = [ |
337 | \' | ', | 318 | \' | ', |
338 | \'\ \ \ / -_) | _| _ \ ` \ -_)', | 319 | \'\ \ \ / -_) | _| _ \ ` \ -_)', |
@@ -351,7 +332,7 @@ let g:vimwiki_list = [{'path': '/home/yigit/Dropbox/personal_wiki', | |||
351 | \ 'css_name': 'tufte.css', | 332 | \ 'css_name': 'tufte.css', |
352 | \ 'auto_export': 1}] | 333 | \ 'auto_export': 1}] |
353 | let g:vimwiki_global_ext = 0 | 334 | let g:vimwiki_global_ext = 0 |
354 | map <Leader>b <Plug>VimwikiToggleListItem | 335 | map <Leader>c <Plug>VimwikiToggleListItem |
355 | "}}} | 336 | "}}} |
356 | 337 | ||
357 | "{{{ yanks/registers and clips | 338 | "{{{ yanks/registers and clips |
@@ -388,6 +369,8 @@ nnoremap X D | |||
388 | 369 | ||
389 | " {{{ vimtex | 370 | " {{{ vimtex |
390 | let g:vimtex_view_method = 'zathura' | 371 | let g:vimtex_view_method = 'zathura' |
391 | let g:vimtex_syntax_enabled = 0 | 372 | " }}} |
392 | 373 | ||
374 | " {{{ rainbow | ||
375 | let g:rainbow_active = 1 | ||
393 | " }}} | 376 | " }}} |