Setting everything during PlugLoad function caused some plugins to misbehave. Plugins are now loaded by Plug and their settings can be either set with a file in the plugin directory (this mimicks the old way of setting plugin up during load) or in after/ directory, which sets options *after* everything has loaded.
25 lines
942 B
VimL
25 lines
942 B
VimL
" PLUGIN: vim-go
|
|
" change the tabstops for go to use tabs and a width of 4
|
|
" this conforms with the gofmt expectations
|
|
au FileType go set noexpandtab
|
|
au FileType go set shiftwidth=4
|
|
au FileType go set softtabstop=4
|
|
au FileType go set tabstop=4
|
|
" enable all sorts of highlighting options for
|
|
" variables/functions/arguments...
|
|
let g:go_highlight_build_constraints = 1
|
|
let g:go_highlight_extra_types = 1
|
|
let g:go_highlight_fields = 1
|
|
let g:go_highlight_functions = 1
|
|
let g:go_highlight_methods = 1
|
|
let g:go_highlight_operators = 1
|
|
let g:go_highlight_structs = 1
|
|
let g:go_highlight_types = 1
|
|
" enable highlighting of other uses of the same variable
|
|
let g:go_auto_sameids = 1
|
|
" automatically import needed dependencies
|
|
" TODO do I need this? not doing it automatically does lead to more conscious
|
|
" decision making on imports
|
|
let g:go_fmt_command = "goimports"
|
|
" show type information for variables in the status line
|
|
let g:go_auto_type_info = 1
|