Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fmt: add support of 'go_list_type' for :GoFmt and :GoImports #1304

Merged
merged 1 commit into from
May 28, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion autoload/go/fmt.vim
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ endfunction
" show_errors opens a location list and shows the given errors. If the given
" errors is empty, it closes the the location list
function! s:show_errors(errors) abort
let l:listtype = "locationlist"
let l:listtype = go#list#Type("locationlist")
if !empty(a:errors)
call go#list#Populate(l:listtype, a:errors, 'Format')
echohl Error | echomsg "Gofmt returned error" | echohl None
Expand Down
7 changes: 4 additions & 3 deletions doc/vim-go.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1382,9 +1382,10 @@ explicitly overrides this behavior. For standard Vim behavior, set it to 10.
<
*'g:go_list_type'*

Specifies the type of list to use. The default value (empty) will use the
appropriate kind of list for the command that was called. Supported values are
"", "quickfix", and "locationlist". >
Specifies the type of list to use for command outputs (such as errors from
builds, results from static analysis commands, etc...). The default value
(empty) will use the appropriate kind of list for the command that was called.
Supported values are "", "quickfix", and "locationlist". >

let g:go_list_type = ""
<
Expand Down