let g:tagbar_type_go = { \ 'ctagstype' : 'go', \ 'kinds' : [ \ 'p:package', \ 'i:imports:1', \ 'c:constants', \ 'v:variables', \ 't:types', \ 'n:interfaces', \ 'w:fields', \ 'e:embedded', \ 'm:methods', \ 'r:constructor', \ 'f:functions' \ ], \ 'sro' : '.', \ 'kind2scope' : { \ 't' : 'ctype', \ 'n' : 'ntype' \ }, \ 'scope2kind' : { \ 'ctype' : 't', \ 'ntype' : 'n' \ }, \ 'ctagsbin' : 'gotags', \ 'ctagsargs' : '-sort -silent' \ } let g:go_auto_type_info = 0 " mappings noremap :TagbarToggle inoremap :TagbarToggle nmap :GoInfo function! MakePublic() let l:wordUnderCursor = expand('') let l:upperCaseWord = substitute(l:wordUnderCursor, '[A-Za-z]', '\\U&', '') execute 'GoRename ' l:upperCaseWord endfunction nmap :GoDocBrowser nmap :GoDoc nmap :call MakePublic() " ALE " let g:ale_linters = {'go':['gofmt', "go build"], 'c':['clang']} let g:ale_linters = {'go':['go build', 'gometalinter', 'gofmt'], 'c':['clang']} let g:ale_fixers = { \ 'go': ['gofmt', 'goimports'], \ 'c': ['clang-format'], \ 'cpp': ['clang-format'], \ 'js': ['eslint'], \ 'python': ['yapf'], \} let g:ale_go_gobuild_options = "-gcflags='-e'" let g:ale_go_gometalinter_options = '--fast' " vim-go let g:go_highlight_functions = 1 let g:go_highlight_space_tab_error = 1 let g:go_highlight_chan_whitespace_error = 1