From 8f6ecbf802cb27bbc0f34e3dfee0263c78f433a2 Mon Sep 17 00:00:00 2001 From: Sebastian Burschel Date: Mon, 6 Sep 2021 22:58:37 +0200 Subject: [PATCH] New linters, plugins and a great function for keeping windows open when closing buffers. --- dotfiles/.vimrc | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/dotfiles/.vimrc b/dotfiles/.vimrc index dc8b5c3..267bda6 100644 --- a/dotfiles/.vimrc +++ b/dotfiles/.vimrc @@ -30,7 +30,7 @@ Plug 'chauncey-garrett/vim-tasklist' " Fuzzy file finder Plug 'ctrlpvim/ctrlp.vim' -" I need thsi for python +" I need this for python Plug 'davidhalter/jedi-vim' " Linter and analyse tool @@ -91,6 +91,8 @@ Plug 'vim-airline/vim-airline-themes' " Shows vertical lines to make indents more visible Plug 'Yggdroot/indentLine' +" Better Javascript indent and syntax support +Plug 'pangloss/vim-javascript' call plug#end() @@ -252,6 +254,7 @@ map gn :bn map gN :bp map gp :bp + " Toggle through splits: nnoremap w w nnoremap W W @@ -279,6 +282,10 @@ map t TaskList map :NERDTreeToggle let NERDTreeIgnore=['\.git$'] +" nerdcommenter settins +let g:NERDCompactSexyComs = 1 +let g:NERDDefaultAlign = 'left' + " airline settings let g:airline#extensions#tabline#enabled = 1 " Show buffers as tabs @@ -286,11 +293,17 @@ let g:airline#extensions#tabline#enabled = 1 " Show buffers as tabs let g:ale_linters = {'python': ['flake8', 'mypy', 'pylint', 'prospector']} let g:ale_fixers = {'python': ['isort', 'black'], \'json': ['fixjson'], + \'html': ['html-beautify', 'tidy'], \'xml': ['xmllint'], \'java': ['uncrustify'], + \'javascript': ['prettier', 'xo', 'standard', 'eslint'], \'tex': ['latexindent']} + +" Run ALEFix shortcut +nnoremap f :ALEFix + " Markdown spellchecking " autocmd FileType markdown setlocal spell spelllang=de " not working yet @@ -418,7 +431,7 @@ nnoremap Kwbd :Kwbd " Create a mapping (e.g. in your .vimrc) like this: "nmap ! Kwbd -nmap d Kwbd +nmap bd Kwbd " Load local config if there is one