diff --git a/vim/after/ftplugin/go.vim b/vim/after/ftplugin/go.vim index 4bc1e1d..6b120b2 100644 --- a/vim/after/ftplugin/go.vim +++ b/vim/after/ftplugin/go.vim @@ -22,7 +22,7 @@ let g:go_fmt_autosave = 0 let g:go_imports_autosave = 1 let g:go_auto_sameids = 0 let g:go_auto_type_info = 0 -let g:go_info_mode = "gopls" +let g:go_info_mode = 'gopls' let g:go_highlight_functions = 1 let g:go_term_enabled = 0 let g:go_term_close_on_exit = 0 diff --git a/vimrc b/vimrc index e0ba84b..dcdea79 100644 --- a/vimrc +++ b/vimrc @@ -222,14 +222,18 @@ let g:ale_rust_analyzer_config = { \ 'checkOnSave': { 'command': 'clippy', 'enable': v:true }, \ } let g:ale_go_goimports_options = '-local github.com/sensiblecodeio/cantabular' +let g:ale_go_gopls_init_options = {'ui.diagnostic.analyses': { + \ 'composites': v:false, + \ 'unusedparams': v:true, + \ 'unusedresult': v:true, + \ 'shadow': v:true, + \ }} " let g:ale_command_wrapper = 'nice -n5' let g:ale_completion_enabled = 0 let g:ale_close_preview_on_insert = 1 let g:ale_hover_to_preview = 1 let g:ale_sign_column_always = 1 let g:ale_history_log_output = 1 -" Currently, gopls only uses default gopls analyzers. -" https://github.com/dense-analysis/ale/issues/3563 let g:ale_linters = { \ 'javascript': ['eslint'], \ 'go': ['gopls'],