45 lines
1.7 KiB
VimL
45 lines
1.7 KiB
VimL
set mouse=a cb=unnamed,unnamedplus wim=longest,list,full backspace=indent,eol,start cmdheight=1 bg=dark nu rnu incsearch cot=menu si sta cpt=.,w,b,i tf foldmethod=syntax path+=** nocompatible sc nosmd cursorline listchars=trail:·,eol:,tab:\ list directory=$HOME/.vim/swap// shortmess=asTI
|
|
filetype plugin indent on
|
|
syntax on
|
|
colorscheme delek
|
|
|
|
cnoremap w!! execute 'silent! write !doas tee % >/dev/null' <bar> edit! <CR>
|
|
cnoremap i! execute 'silent! write !doas make install' <CR>
|
|
function! CleverTab()
|
|
if strpart( getline('.'), col('.')-2, 3) =~ '^\w'
|
|
if &completefunc
|
|
return "\<C-X>\<C-U>"
|
|
elseif exists('b:compkey')
|
|
return b:compkey
|
|
else
|
|
return "\<C-X>\<C-I>"
|
|
endif
|
|
else
|
|
return "\<Tab>"
|
|
endif
|
|
endfunction
|
|
inoremap <Tab> <C-R>=CleverTab()<CR>
|
|
|
|
autocmd FileType yaml setlocal sw=8 sts=8 expandtab
|
|
|
|
autocmd FileType tex command! Comp execute 'silent !pdflatex %' <bar> redraw!
|
|
autocmd FileType less command! Comp execute 'silent !lessc % %:r.css' <bar> redraw!
|
|
autocmd FileType tex command! Compdoc execute 'silent !pandoc -t docx % -o %:r.docx' <bar> redraw!
|
|
|
|
let g:lsc_server_commands = {'c': { 'command': 'clangd --completion-style=detailed --suggest-missing-includes --clang-tidy -j=8', 'suppress_stderr': v:true }}
|
|
let g:lsc_auto_map = v:true
|
|
let g:lsc_enable_autocomplete = v:true
|
|
|
|
let g:netrw_banner = 0
|
|
let g:netrw_liststile = 3
|
|
|
|
let g:airline_powerline_fonts = v:true
|
|
let g:airline#extensions#tabline#enabled = v:true
|
|
let g:airline_skip_empty_sections = v:true
|
|
let g:airline_theme='term'
|
|
|
|
let g:clang_format#code_style = 'llvm'
|
|
let g:clang_format#detect_style_file = v:true
|
|
let g:clang_format#auto_format = v:true
|
|
let g:clang_format#enable_fallback_style = 0
|