diff options
Diffstat (limited to '.config/nvim/init.vim')
-rwxr-xr-x | .config/nvim/init.vim | 607 |
1 files changed, 0 insertions, 607 deletions
diff --git a/.config/nvim/init.vim b/.config/nvim/init.vim deleted file mode 100755 index 40fadf2..0000000 --- a/.config/nvim/init.vim +++ /dev/null | |||
@@ -1,607 +0,0 @@ | |||
1 | let g:polyglot_disabled=['latex', 'tex'] | ||
2 | |||
3 | "{{{ Plugs | ||
4 | call plug#begin('~/.local/share/nvim/plugged') | ||
5 | |||
6 | " latex " had to move vimtex to top to avoid a difficult error | ||
7 | Plug 'lervag/vimtex', { 'for': ['tex', 'latex', 'plaintex']} | ||
8 | autocmd User vimtex call deoplete#custom#var('omni', 'input_patterns', { | ||
9 | \ 'tex': g:vimtex#re#deoplete | ||
10 | \}) | ||
11 | |||
12 | " Vimscript debugger | ||
13 | " Plug 'vim-scripts/Decho' | ||
14 | |||
15 | " completion, 'lsp' and coding {{{ " | ||
16 | |||
17 | " completion framework | ||
18 | Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } | ||
19 | Plug 'lionawurscht/deoplete-biblatex' | ||
20 | Plug 'deoplete-plugins/deoplete-jedi' | ||
21 | " rust code completion & navigation | ||
22 | Plug 'racer-rust/vim-racer' | ||
23 | " syntax checking | ||
24 | Plug 'dense-analysis/ale' | ||
25 | " manages tag files | ||
26 | Plug 'ludovicchabant/vim-gutentags' | ||
27 | " run tests (todo: write tests) | ||
28 | Plug 'janko/vim-test' | ||
29 | " type in file send to repl | ||
30 | Plug 'jpalardy/vim-slime' | ||
31 | " snippets to expand | ||
32 | Plug 'SirVer/ultisnips' | Plug 'honza/vim-snippets' | ||
33 | " Highlight the yanked region | ||
34 | Plug 'machakann/vim-highlightedyank' | ||
35 | |||
36 | " auto pair plugin, people hate these | ||
37 | Plug 'tmsvg/pear-tree' | ||
38 | " language packs | ||
39 | Plug 'sheerun/vim-polyglot' | ||
40 | " i3 config syntax | ||
41 | Plug 'mboughaba/i3config.vim' | ||
42 | " git diff in the sign column | ||
43 | Plug 'airblade/vim-gitgutter' | ||
44 | " gitk apparently | ||
45 | Plug 'cohama/agit.vim' | ||
46 | " completion preview of floating window | ||
47 | Plug 'ncm2/float-preview.nvim' | ||
48 | " switch between single line and multiline | ||
49 | Plug 'AndrewRadev/splitjoin.vim' | ||
50 | |||
51 | " }}} completion, 'lsp' and such " | ||
52 | |||
53 | " heresy {{{ " | ||
54 | |||
55 | " Fuzzy finder with post-update hook | ||
56 | Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } | ||
57 | Plug 'junegunn/fzf.vim' | ||
58 | |||
59 | " TODO let's try out fern.vim | ||
60 | Plug 'lambdalisue/fern.vim' | ||
61 | " TODO bug in neovim, so required for now | ||
62 | " https://github.com/lambdalisue/fern.vim/issues/120 | ||
63 | Plug 'antoinemadec/FixCursorHold.nvim' | ||
64 | |||
65 | " displays tags ordered by scope | ||
66 | Plug 'majutsushi/tagbar' | ||
67 | " status/tabline | ||
68 | Plug 'vim-airline/vim-airline' | ||
69 | Plug 'vim-airline/vim-airline-themes' | ||
70 | " undo tree visualizer | ||
71 | Plug 'mbbill/undotree' | ||
72 | " preview colours in source code | ||
73 | Plug 'ap/vim-css-color' | ||
74 | " kitty config filetype | ||
75 | Plug 'fladson/vim-kitty' | ||
76 | " }}} heresy " | ||
77 | |||
78 | " colour theme of $CURRENT_YEAR | ||
79 | Plug 'rose-pine/neovim' | ||
80 | |||
81 | " prose, note taking {{{ " | ||
82 | |||
83 | " Personal wiki | ||
84 | Plug 'vimwiki/vimwiki' | ||
85 | " centers the writing | ||
86 | Plug 'junegunn/goyo.vim' | ||
87 | " highlights the current paragraph | ||
88 | Plug 'junegunn/limelight.vim' | ||
89 | " thesaurus query & replacement | ||
90 | Plug 'ron89/thesaurus_query.vim' | ||
91 | " change ASCII text to Turkish text | ||
92 | Plug 'yigitsever/turkish-deasciifier.vim' | ||
93 | " }}} prose, note taking " | ||
94 | |||
95 | " movement, editing {{{ " | ||
96 | |||
97 | " text alignment \w :Tab | ||
98 | Plug 'godlygeek/tabular' | ||
99 | " move selections up and down with alt+[j,k] | ||
100 | Plug 'matze/vim-move' | ||
101 | " surround text objects; sa, sr and sd | ||
102 | Plug 'machakann/vim-sandwich' | ||
103 | " provide additional text objects | ||
104 | Plug 'wellle/targets.vim' | ||
105 | " indentation level text object, ia, ii | ||
106 | Plug 'michaeljsmith/vim-indent-object' | ||
107 | " visual feedback for substitute holy shit this is amazing | ||
108 | Plug 'markonm/traces.vim' | ||
109 | " see the contents of registers on "/<CTRL-R> | ||
110 | Plug 'junegunn/vim-peekaboo' | ||
111 | " use <leader>k to highlight multiple words | ||
112 | Plug 'lfv89/vim-interestingwords' | ||
113 | " swap delimited items using g>, g< | ||
114 | Plug 'machakann/vim-swap' | ||
115 | " jump to location by 2 characters, ` | ||
116 | Plug 'justinmk/vim-sneak' | ||
117 | " reopen files at your last edit position | ||
118 | Plug 'farmergreg/vim-lastplace' | ||
119 | " flash cursor on jump | ||
120 | Plug 'DanilaMihailov/beacon.nvim' | ||
121 | " ascii drawing plugin | ||
122 | Plug 'vim-scripts/DrawIt' | ||
123 | |||
124 | " }}} movement, editing " | ||
125 | |||
126 | " vim-easyclip suite {{{ " | ||
127 | |||
128 | " splits delete into cut and delete | ||
129 | Plug 'svermeulen/vim-cutlass' | ||
130 | " change text with yank | ||
131 | Plug 'svermeulen/vim-subversive' | ||
132 | " yank history | ||
133 | Plug 'svermeulen/vim-yoink' | ||
134 | |||
135 | " }}} vim-easyclip suite " | ||
136 | |||
137 | " tpope {{{ " | ||
138 | |||
139 | " enable repeating supported plugin maps with '.' | ||
140 | Plug 'tpope/vim-repeat' | ||
141 | " pairs of handy bracket mappings | ||
142 | Plug 'tpope/vim-unimpaired' | ||
143 | " git wrapper | ||
144 | Plug 'tpope/vim-fugitive' | ||
145 | " increment dates, times & more | ||
146 | Plug 'tpope/vim-speeddating' | ||
147 | " search, substitute and abbreviate | ||
148 | Plug 'tpope/vim-abolish' | ||
149 | " provides ga, show unicode stuff of char under cursor | ||
150 | Plug 'tpope/vim-characterize' | ||
151 | " comment helper | ||
152 | Plug 'tpope/vim-commentary' | ||
153 | " asynchronous build and test dispatcher | ||
154 | Plug 'tpope/vim-dispatch' | ||
155 | " }}} tpope " | ||
156 | |||
157 | " fancy start screen | ||
158 | Plug 'mhinz/vim-startify' | ||
159 | " asks to be placed last, sure | ||
160 | Plug 'ryanoasis/vim-devicons' | ||
161 | call plug#end() | ||
162 | |||
163 | "}}} | ||
164 | |||
165 | "{{{Auto Commands | ||
166 | " Remove any trailing whitespace that is in the file | ||
167 | autocmd BufRead,BufWrite * if ! &bin | silent! %s/\s\+$//ge | endif | ||
168 | |||
169 | " Close vim if the only window left open is a quickfix window | ||
170 | autocmd WinEnter * if winnr("$") == 1 && &buftype == "quickfix" | q | endif | ||
171 | " winnr("$") how many windows left? | ||
172 | |||
173 | " Resize all windows proportionally when the terminal is resized | ||
174 | " let terminal resize scale the internal windows | ||
175 | autocmd VimResized * :wincmd = | ||
176 | |||
177 | " Set spell for prose | ||
178 | autocmd FileType markdown,tex setlocal spell | ||
179 | |||
180 | " Dispatch.vim plugin to use cargo run for rust projects | ||
181 | autocmd FileType rust let b:dispatch = 'cargo run' | ||
182 | |||
183 | " these files are formatted not with textwidth but into sentences | ||
184 | autocmd FileType vimwiki,latex,tex setlocal formatprg=/home/yigit/.local/bin/sentences | ||
185 | |||
186 | " runs a script that cleans out tex build files whenever I close out of a .tex file. | ||
187 | autocmd VimLeave *.tex !texclear % | ||
188 | "}}} | ||
189 | |||
190 | " Functions {{{ | ||
191 | |||
192 | function! CreateNote() | ||
193 | py3 import uuid | ||
194 | exe "e! " . fnameescape("~/nextcloud/personal_wiki/text/box/" . py3eval('str(uuid.uuid4())[:6]') . ".wiki") | ||
195 | let l:text="= up =\n\n= down =\n\n= keywords =\n\n" | ||
196 | put =l:text | ||
197 | norm gg | ||
198 | endfunction | ||
199 | |||
200 | function! CreatePaper(citekey) | ||
201 | exe "e! " . fnameescape("~/nextcloud/personal_wiki/text/papers/" . a:citekey . ".wiki") | ||
202 | |||
203 | let l:timestap="%date " . strftime("%F") | ||
204 | let l:text="= Came From =\n\n= Takeaways =\n\n= Might Go To =\n\n" | ||
205 | |||
206 | put! =l:timestap | ||
207 | put =l:text | ||
208 | endfunction | ||
209 | |||
210 | function! CreateReference(citekey) | ||
211 | exe "e! " . fnameescape("~/nextcloud/personal_wiki/text/reference/" . a:citekey . ".wiki") | ||
212 | |||
213 | let l:timestap="%date " . strftime("%F") | ||
214 | let l:text="= Literature Notes =\n\n= Citation =\n\n" | ||
215 | |||
216 | put! =l:timestap | ||
217 | put =l:text | ||
218 | endfunction | ||
219 | |||
220 | " }}} Function " | ||
221 | |||
222 | "{{{Settings | ||
223 | |||
224 | " fix the Target STRING not available | ||
225 | let g:clipboard = { | ||
226 | \ 'name': 'xsel_override', | ||
227 | \ 'copy': { | ||
228 | \ '+': 'xsel --input --clipboard', | ||
229 | \ '*': 'xsel --input --primary', | ||
230 | \ }, | ||
231 | \ 'paste': { | ||
232 | \ '+': 'xsel --output --clipboard', | ||
233 | \ '*': 'xsel --output --primary', | ||
234 | \ }, | ||
235 | \ 'cache_enabled': 1, | ||
236 | \ } | ||
237 | |||
238 | " Use deoplete. | ||
239 | let g:deoplete#enable_at_startup = 1 | ||
240 | let g:deoplete#sources#biblatex#bibfile = '~/.local/share/vim_biblatex.bib' | ||
241 | |||
242 | " interact with system clipboard | ||
243 | set clipboard+=unnamedplus | ||
244 | |||
245 | " required for yoink/cutlass/subversive interaction | ||
246 | let g:yoinkIncludeDeleteOperations = 1 | ||
247 | |||
248 | " Tab stuff | ||
249 | set autoindent | ||
250 | |||
251 | " :h tabstop, 2. point | ||
252 | " Use appropriate number of spaces to insert a <Tab> | ||
253 | set expandtab | ||
254 | set shiftwidth=4 | ||
255 | set softtabstop=4 | ||
256 | set tabstop=8 | ||
257 | |||
258 | " Use english for spellchecking, but don't spellcheck by default | ||
259 | set spell spelllang=en_gb | ||
260 | set nospell | ||
261 | |||
262 | " Tab completion, zsh style | ||
263 | set wildmode=full | ||
264 | set wildignore=*.o,*.obj,*.class,*.aux,*.lof,*.log,*.lot,*.fls,*.toc,*.fmt,*.fot,*.cb,*.cb2,.*.lb,.dvi,*.xdv,*.bbl,*.bcf,*.blg,*-blx.aux,*-blx.bib,*.run.xml,*.fdb_latexmk,*.synctex,*.synctex(busy),*.synctex.gz,*.synctex.gz(busy),*.pdfsync | ||
265 | |||
266 | " Put one space while joining (not two) | ||
267 | set nojoinspaces | ||
268 | |||
269 | " Keep n lines above/below cursor while scrolling | ||
270 | set scrolloff=4 | ||
271 | " line numbers | ||
272 | set number | ||
273 | " fold manually, when I place markers | ||
274 | set foldmethod=marker | ||
275 | " set terminal title | ||
276 | set title | ||
277 | " wrap using 'breakat' character | ||
278 | set linebreak | ||
279 | " new split panes will split to below and right | ||
280 | set splitbelow | ||
281 | set splitright | ||
282 | " highlight the current line, yoc undoes | ||
283 | set cursorline | ||
284 | " current line actual number, rest are relative | ||
285 | set relativenumber | ||
286 | " we are already using airline, don't clobber linter messages | ||
287 | set noshowmode | ||
288 | " jump to the matching bracket briefly | ||
289 | set showmatch | ||
290 | " move freely between buffers | ||
291 | set hidden | ||
292 | |||
293 | " persistent undo | ||
294 | set undodir=~/.vim/undodir | ||
295 | set undofile | ||
296 | |||
297 | " lower case searches ignore case, upper case searches do not | ||
298 | set ignorecase | ||
299 | set smartcase | ||
300 | |||
301 | " https://stackoverflow.com/a/3445040/ | ||
302 | " switch case labels | ||
303 | set cinoptions=l1 | ||
304 | |||
305 | " https://www.reddit.com/r/vim/comments/7bj837/favorite_console_tools_to_use_with_vim/ | ||
306 | if executable('rg') | ||
307 | set grepprg=rg\ --vimgrep\ --no-heading\ --smart-case | ||
308 | endif | ||
309 | |||
310 | set diffopt=algorithm:patience | ||
311 | |||
312 | let g:float_preview#docked = 0 | ||
313 | set completeopt = "menu" | ||
314 | |||
315 | " }}} | ||
316 | |||
317 | "{{{Look and Feel | ||
318 | set termguicolors | ||
319 | colorscheme rose-pine | ||
320 | |||
321 | highlight HighlightedyankRegion cterm=reverse gui=reverse | ||
322 | let g:highlightedyank_highlight_duration = 200 | ||
323 | " }}} | ||
324 | |||
325 | "{{{ Mappings | ||
326 | |||
327 | " brute force deasciify everything | ||
328 | nnoremap <expr> <Leader>tc TurkishDeasciifyForce() | ||
329 | xnoremap <expr> <Leader>tc TurkishDeasciifyForce() | ||
330 | nnoremap <expr> <Leader>tctc TurkishDeasciifyForce() .. '_' | ||
331 | |||
332 | " use turkish-mode to selectively deasciify | ||
333 | nnoremap <expr> <Leader>tr TurkishDeasciify() | ||
334 | xnoremap <expr> <Leader>tr TurkishDeasciify() | ||
335 | nnoremap <expr> <Leader>trtr TurkishDeasciify() .. '_' | ||
336 | |||
337 | " ascii everything | ||
338 | nnoremap <expr> <Leader>rt TurkishAsciify() | ||
339 | xnoremap <expr> <Leader>rt TurkishAsciify() | ||
340 | nnoremap <expr> <Leader>rtrt TurkishAsciify() .. '_' | ||
341 | |||
342 | " https://stackoverflow.com/questions/4256697/vim-search-and-highlight-but-do-not-jump | ||
343 | nnoremap * :keepjumps normal! mi*`i<CR> | ||
344 | nnoremap # :keepjumps normal! mi#`i<CR> | ||
345 | |||
346 | " Save file as sudo on files that require root permission | ||
347 | cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit! | ||
348 | |||
349 | " replace ex mode with gq | ||
350 | map Q gq | ||
351 | |||
352 | " set formatprg to sentences, for prose | ||
353 | map \fp :set formatprg=~/.local/bin/sentences<CR> | ||
354 | |||
355 | " Replace all is aliased to S. | ||
356 | nnoremap S :%s//g<Left><Left> | ||
357 | |||
358 | " use esc in :term as well | ||
359 | tnoremap <Esc> <C-\><C-n> | ||
360 | |||
361 | " call CreatePaper on word below cursor | ||
362 | nnoremap <leader>np gewi[[/papers/<ESC>Ea]]<ESC>bb:call CreatePaper(expand('<cword>'))<CR> | ||
363 | |||
364 | " link paper | ||
365 | nnoremap <leader>lp gewi[[/papers/<ESC>Ea]]<ESC> | ||
366 | |||
367 | " call CreateReference on word below cursor | ||
368 | nnoremap <leader>nr :call CreateReference(expand('<cword>'))<CR> | ||
369 | |||
370 | " create a new note | ||
371 | nnoremap <leader>nn :call CreateNote()<CR> | ||
372 | |||
373 | " If you like "Y" to work from the cursor to the end of line (which is more | ||
374 | " logical, but not Vi-compatible) | ||
375 | map Y y$ | ||
376 | |||
377 | " Open the TagBar Plugin <F3> | ||
378 | nnoremap <silent> <F3> :TagbarToggle<CR> | ||
379 | " Fix whole buffer via ALE | ||
380 | nmap <F9> <Plug>(ale_fix) | ||
381 | |||
382 | " vim-test bindings | ||
383 | nmap <silent> t<C-n> :TestNearest<CR> | ||
384 | nmap <silent> t<C-f> :TestFile<CR> | ||
385 | nmap <silent> t<C-s> :TestSuite<CR> | ||
386 | nmap <silent> t<C-l> :TestLast<CR> | ||
387 | nmap <silent> t<C-g> :TestVisit<CR> | ||
388 | |||
389 | " Edit vimrc \ev | ||
390 | nnoremap <silent> <leader>ev :tabnew<CR>:e ~/.config/nvim/init.vim<CR> | ||
391 | " jump to buffer | ||
392 | nnoremap <leader>b :ls<cr>:b<space> | ||
393 | |||
394 | " Up and down are more logical with g.. | ||
395 | nnoremap <silent> k gk | ||
396 | nnoremap <silent> j gj | ||
397 | inoremap <silent> <Up> <Esc>gka | ||
398 | inoremap <silent> <Down> <Esc>gja | ||
399 | |||
400 | " Disable highlight when <leader><cr> is pressed | ||
401 | nnoremap <silent> <leader><cr> :noh<cr> | ||
402 | " Space used to toggle folds, now it's x (because x is d) | ||
403 | nnoremap <space> "_x | ||
404 | |||
405 | " checkmarks on vimwiki | ||
406 | nmap <leader>v <Plug>VimwikiToggleListItem | ||
407 | " add/increase header level | ||
408 | nmap <leader>a <Plug>VimwikiAddHeaderLevel | ||
409 | |||
410 | " sneak using grave, s is for sandwich | ||
411 | nmap ` <Plug>Sneak_s | ||
412 | nmap <leader>` <Plug>Sneak_S | ||
413 | nnoremap ' ` | ||
414 | |||
415 | " separate cut and delete | ||
416 | nnoremap x d | ||
417 | xnoremap x d | ||
418 | nnoremap xx dd | ||
419 | nnoremap X D | ||
420 | |||
421 | " use the special yoink paste | ||
422 | nmap p <plug>(YoinkPaste_p) | ||
423 | nmap P <plug>(YoinkPaste_P) | ||
424 | |||
425 | " substitute from yank | ||
426 | nmap <leader>ys <plug>(SubversiveSubstitute) | ||
427 | nmap <leader>yss <plug>(SubversiveSubstituteLine) | ||
428 | nmap <leader>yS <plug>(SubversiveSubstituteToEndOfLine) | ||
429 | |||
430 | " substitute over range | ||
431 | nmap <leader>s <plug>(SubversiveSubstituteRange) | ||
432 | xmap <leader>s <plug>(SubversiveSubstituteRange) | ||
433 | nmap <leader>ss <plug>(SubversiveSubstituteWordRange) | ||
434 | |||
435 | " subvert over range | ||
436 | nmap <leader><leader>s <plug>(SubversiveSubvertRange) | ||
437 | xmap <leader><leader>s <plug>(SubversiveSubvertRange) | ||
438 | nmap <leader><leader>ss <plug>(SubversiveSubvertWordRange) | ||
439 | |||
440 | " iterate over yank list | ||
441 | nmap <c-n> <plug>(YoinkPostPasteSwapBack) | ||
442 | nmap <c-p> <plug>(YoinkPostPasteSwapForward) | ||
443 | |||
444 | " change into pwd of current directory | ||
445 | nnoremap <leader>cd :cd %:p:h<CR>:pwd<CR> | ||
446 | inoremap <silent> <leader>fn <C-R>=expand("%:t:r")<CR> | ||
447 | nnoremap <silent> <leader>fn :put! =expand('%:t:r')<CR> | ||
448 | |||
449 | " press \g and start writing prose | ||
450 | map <leader>g :Goyo<CR> | ||
451 | "}}} | ||
452 | |||
453 | "{{{Tagbar | ||
454 | let g:tagbar_autofocus = 1 | ||
455 | let g:tagbar_compact = 1 | ||
456 | let g:tagbar_sort = 0 | ||
457 | let g:tagbar_width = 25 | ||
458 | "}}} | ||
459 | |||
460 | "{{{ Airline | ||
461 | let g:airline_powerline_fonts = 1 | ||
462 | let g:airline#extensions#tabline#formatter = 'unique_tail' | ||
463 | let g:airline#extensions#tabline#enabled = 1 | ||
464 | let g:airline_mode_map = {} | ||
465 | let g:airline_mode_map['ic'] = 'INSERT' | ||
466 | |||
467 | if !exists('g:airline_symbols') | ||
468 | let g:airline_symbols = {} | ||
469 | endif | ||
470 | |||
471 | let g:airline_left_sep = '' | ||
472 | let g:airline_left_alt_sep = '' | ||
473 | let g:airline_right_sep = '' | ||
474 | let g:airline_right_alt_sep = '' | ||
475 | |||
476 | "}}} | ||
477 | |||
478 | "{{{ Ale | ||
479 | let g:ale_sign_error = '✗' | ||
480 | let g:ale_sign_warning = '⚑' | ||
481 | let g:ale_lint_on_text_changed = 'insert' | ||
482 | let g:ale_lint_on_enter = 0 | ||
483 | let g:ale_pattern_options = {'\.wiki$': {'ale_enabled': 0}} | ||
484 | "}}} | ||
485 | |||
486 | "{{{ Ledger | ||
487 | let g:ledger_maxwidth = 48 | ||
488 | let g:ledger_fillstring = ' ~' | ||
489 | "}}} | ||
490 | |||
491 | "{{{ UltiSnips | ||
492 | set runtimepath+=~/.vim/my-snippets/ | ||
493 | let g:UltiSnipsEditSplit = "vertical" | ||
494 | let g:UltiSnipsSnippetsDir = $HOME.'/.vim/my-snippets/UltiSnips' | ||
495 | |||
496 | " ctrl + l expands the snippet, c + j/k navigates placeholders | ||
497 | let g:UltiSnipsExpandTrigger = "<C-l>" | ||
498 | let g:UltiSnipsEnableSnipMate = "1" | ||
499 | "}}} | ||
500 | |||
501 | "{{{ vim-startify | ||
502 | function! StartifyEntryFormat() | ||
503 | return 'WebDevIconsGetFileTypeSymbol(absolute_path) ." ". entry_path' | ||
504 | endfunction | ||
505 | |||
506 | let entry_format = "' ['. index .']'. repeat(' ', (3 - strlen(index)))" | ||
507 | |||
508 | if exists('*WebDevIconsGetFileTypeSymbol') " support for vim-devicons | ||
509 | let entry_format .= ". WebDevIconsGetFileTypeSymbol(entry_path) .' '. entry_path" | ||
510 | else | ||
511 | let entry_format .= '. entry_path' | ||
512 | endif | ||
513 | |||
514 | let g:ascii = [ | ||
515 | \' | ', | ||
516 | \'\ \ \ / -_) | _| _ \ ` \ -_)', | ||
517 | \' \_/\_/\___|_|\__|\___/_|_|_|\___|', | ||
518 | \ '', | ||
519 | \] | ||
520 | |||
521 | let g:startify_custom_header = | ||
522 | \ 'map(g:ascii + startify#fortune#boxed(), "\" \".v:val")' | ||
523 | |||
524 | "}}} | ||
525 | |||
526 | "{{{ vimwiki | ||
527 | let g:vimwiki_list = [{'path': '/home/yigit/nextcloud/personal_wiki/text', | ||
528 | \ 'path_html': '/home/yigit/nextcloud/personal_wiki/html', | ||
529 | \ 'auto_generate_tags': 1, | ||
530 | \ 'automatic_nested_syntaxes': 1, | ||
531 | \ 'template_path': '/home/yigit/nextcloud/personal_wiki/templates', | ||
532 | \ 'template_default': 'default_template', | ||
533 | \ 'template_ext': '.html', | ||
534 | \ 'auto_export': 1, | ||
535 | \ 'auto_tags': 1}] | ||
536 | let g:vimwiki_global_ext = 0 | ||
537 | let g:vimwiki_hl_headers = 1 | ||
538 | "}}} | ||
539 | |||
540 | " {{{ vimtex | ||
541 | let g:vimtex_view_method='zathura' | ||
542 | let g:vimtex_quickfix_mode=0 | ||
543 | " }}} | ||
544 | |||
545 | " {{{ Gutentags | ||
546 | let g:gutentags_enabled = 1 | ||
547 | let g:gutentags_add_default_project_roots = 0 | ||
548 | let g:gutentags_project_root = ['Makefile', '.git'] | ||
549 | let g:gutentags_exclude_filetypes = ['gitcommit', 'gitconfig', 'gitrebase', 'gitsendemail', 'git'] | ||
550 | let g:gutentags_generate_on_new = 1 | ||
551 | let g:gutentags_generate_on_missing = 1 | ||
552 | let g:gutentags_generate_on_write = 1 | ||
553 | let g:gutentags_generate_on_empty_buffer = 0 | ||
554 | let g:gutentags_ctags_exclude = [ | ||
555 | \ '*.git', '*.svn', '*.hg', | ||
556 | \ 'cache', 'build', 'dist', 'bin', 'node_modules', 'bower_components', | ||
557 | \ '*-lock.json', '*.lock', | ||
558 | \ '*.min.*', | ||
559 | \ '*.bak', | ||
560 | \ '*.zip', | ||
561 | \ '*.pyc', | ||
562 | \ '*.class', | ||
563 | \ '*.sln', | ||
564 | \ '*.csproj', '*.csproj.user', | ||
565 | \ '*.tmp', | ||
566 | \ '*.cache', | ||
567 | \ '*.vscode', | ||
568 | \ '*.pdb', | ||
569 | \ '*.exe', '*.dll', '*.bin', | ||
570 | \ '*.mp3', '*.ogg', '*.flac', | ||
571 | \ '*.swp', '*.swo', | ||
572 | \ '.DS_Store', '*.plist', | ||
573 | \ '*.bmp', '*.gif', '*.ico', '*.jpg', '*.png', '*.svg', | ||
574 | \ '*.rar', '*.zip', '*.tar', '*.tar.gz', '*.tar.xz', '*.tar.bz2', | ||
575 | \ '*.pdf', '*.doc', '*.docx', '*.ppt', '*.pptx', '*.xls', | ||
576 | \] | ||
577 | " }}} | ||
578 | |||
579 | " vim-slime {{{ | ||
580 | let g:slime_target = "tmux" | ||
581 | let g:slime_paste_file = "$HOME/.slime_paste" | ||
582 | let g:slime_default_config = {"socket_name": get(split($TMUX, ","), 0), "target_pane": "{last}"} | ||
583 | " }}} Slime | ||
584 | |||
585 | " devicons {{{ " | ||
586 | let g:WebDevIconsUnicodeDecorateFileNodesExtensionSymbols = {} " needed | ||
587 | let g:WebDevIconsUnicodeDecorateFileNodesExtensionSymbols['wiki'] = '📔' | ||
588 | " }}} devicons " | ||
589 | |||
590 | " beacon {{{ " | ||
591 | let g:beacon_size = 100 | ||
592 | let g:beacon_shrink = 0 | ||
593 | highlight Beacon guibg=red ctermbg=15 | ||
594 | " }}} beacon " | ||
595 | |||
596 | " thesaurus_query {{{ " | ||
597 | let g:tq_enabled_backends = ["mthesaur_txt"] | ||
598 | let g:tq_truncation_on_relavance = 0 | ||
599 | " }}} thesaurus_query " | ||
600 | |||
601 | " fzf.vim {{{ " | ||
602 | " Insert mode completion | ||
603 | imap <c-x><c-k> <plug>(fzf-complete-word) | ||
604 | imap <c-x><c-f> <plug>(fzf-complete-path) | ||
605 | imap <c-x><c-l> <plug>(fzf-complete-line) | ||
606 | " }}} fzf.vim " | ||
607 | |||