aboutsummaryrefslogtreecommitdiff
path: root/vim/ftplugin
diff options
context:
space:
mode:
Diffstat (limited to 'vim/ftplugin')
-rw-r--r--vim/ftplugin/c.vim10
-rw-r--r--vim/ftplugin/cpp.vim7
-rw-r--r--vim/ftplugin/python.vim5
3 files changed, 14 insertions, 8 deletions
diff --git a/vim/ftplugin/c.vim b/vim/ftplugin/c.vim
index 9b9cd90..3464e2d 100644
--- a/vim/ftplugin/c.vim
+++ b/vim/ftplugin/c.vim
@@ -1,6 +1,10 @@
-let b:ale_linters = ['cppcheck', 'ccls', 'flawfinder']
-let b:ale_fixers = ['remove_trailing_lines', 'trim_whitespace']
-"let g:ale_c_parse_compile_commands = 1
+setlocal colorcolumn=120
+setlocal textwidth=120
+
+let b:ale_linters = ['ccls', 'cppcheck', 'flawfinder', 'clangtidy']
+let b:ale_fixers = ['clang-format', 'remove_trailing_lines', 'trim_whitespace']
+let g:ale_c_ccls_init_options = {'cache': {'directory': '/tmp/ccls/cache'}}
+let g:ale_c_parse_compile_commands = 1
nmap <F8> :ALENext<cr>
nmap <F7> :ALEPrevious<cr>
diff --git a/vim/ftplugin/cpp.vim b/vim/ftplugin/cpp.vim
index 7d278bf..7086bfb 100644
--- a/vim/ftplugin/cpp.vim
+++ b/vim/ftplugin/cpp.vim
@@ -1,7 +1,8 @@
" This is for C but vim defines *.h as cpp type so here we have it
-let b:ale_linters = ['cppcheck', 'cquery']
-let b:ale_fixers = ['remove_trailing_lines', 'trim_whitespace']
-"let g:ale_c_parse_compile_commands = 1
+let b:ale_linters = ['ccls', 'cppcheck', 'flawfinder', 'clangtidy']
+let b:ale_fixers = ['clang-format', 'remove_trailing_lines', 'trim_whitespace']
+let g:ale_cpp_ccls_init_options = {'cache': {'directory': '/tmp/ccls/cache'}}
+let g:ale_cpp_parse_compile_commands = 1
nmap <F8> :ALENext<cr>
nmap <F7> :ALEPrevious<cr>
diff --git a/vim/ftplugin/python.vim b/vim/ftplugin/python.vim
index 4b74224..8528d50 100644
--- a/vim/ftplugin/python.vim
+++ b/vim/ftplugin/python.vim
@@ -1,5 +1,6 @@
setlocal colorcolumn=120
setlocal textwidth=120
-let b:ale_linters = ['flake8', 'pylint', 'pyls']
-let b:ale_fixers = ['autopep8', 'isort', 'black', 'add_blank_lines_for_python_control_statements', 'remove_trailing_lines', 'trim_whitespace']
+let b:ale_linters = ['pyls']
+let b:ale_fixers = ['isort', 'black', 'add_blank_lines_for_python_control_statements', 'remove_trailing_lines', 'trim_whitespace']
+let g:ale_python_pyls_executable = 'pylsp'