1
0

Replace syntastic with Ale

This commit is contained in:
2019-10-05 18:46:34 +02:00
parent a80d584fc8
commit 36d5207b43

36
vimrc
View File

@ -1,6 +1,3 @@
" For platform specific settings
let hostname = substitute(system('hostname'), '\n', '', '')
" Plugin management
set nocompatible
filetype off
@ -15,19 +12,10 @@ Plugin 'scrooloose/nerdtree', { 'on': 'NERDTreeToggle' }
Plugin 'ctrlpvim/ctrlp.vim'
" Class explorer
Plugin 'majutsushi/tagbar', { 'on': 'TagbarToggle' }
" Code completion using <tab>
Plugin 'ervandew/supertab'
if hostname == "localhost"
" Autocompletion
Plugin 'ycm-core/YouCompleteMe'
" Syntax check
Plugin 'vim-syntastic/syntastic'
else
" Autocomplete for python
Plugin 'davidhalter/jedi-vim'
" Asynchronous syntax check
Plugin 'dense-analysis/ale'
endif
" Intelligent folding
Plugin 'tmhedberg/SimpylFold'
" Git management
@ -59,10 +47,6 @@ set shiftwidth=0
set autoindent
set smarttab
autocmd filetype python set expandtab
au BufNewFile,BufRead *.js, *.html, *.css, *.json
\ set tabstop=2 |
\ set softtabstop=2 |
\ set shiftwidth=2
" Display
set list
@ -88,25 +72,9 @@ nmap <F5> :w<CR>:!clear;python3 %<CR>
nmap <F6> :!%:p<CR>
nmap <F7> :NERDTreeToggle<CR>
nmap <F8> :TagbarToggle<CR>
nmap <C-Up> :lprevious<CR>
nmap <C-Down> :lnext<CR>
" Plugin config
let g:SimpylFold_docstring_preview=1
let g:airline#extensions#tabline#enabled=1
if hostname == "localhost"
let g:syntastic_always_populate_loc_list = 1
let g:syntastic_auto_loc_list = 1
let g:syntastic_check_on_open = 1
let g:syntastic_check_on_wq = 0
else
let g:airline_powerline_fonts=1
" Plugin Ale
packloadall
silent! helptags ALL
let g:ale_fixers = {
\ '*': ['remove_trailing_lines', 'trim_whitespace'],
\ 'javascript': ['eslint'],
\ 'python': ['add_blank_lines_for_python_control_statements', 'autopep8', 'isort']
\}
endif