Skip to content

Commit

Permalink
Simpler quickfix behavior
Browse files Browse the repository at this point in the history
Previous behavior was based on my incorrect assumption that :cwindow
would open for only invalid entries.
  • Loading branch information
tpope committed Jun 20, 2014
1 parent e204799 commit b0ce647
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
6 changes: 1 addition & 5 deletions autoload/dispatch.vim
Original file line number Diff line number Diff line change
Expand Up @@ -642,11 +642,7 @@ endfunction

function! s:open_quickfix(request, copen) abort
let was_qf = &buftype ==# 'quickfix'
if a:copen || !empty(filter(getqflist(), 'v:val.valid'))
copen
else
cclose
endif
execute 'botright' (a:copen ? 'copen' : 'cwindow')
if &buftype ==# 'quickfix' && !was_qf && !a:copen
wincmd p
endif
Expand Down
3 changes: 1 addition & 2 deletions doc/dispatch.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ COMMANDS *dispatch-commands*
build in the foreground. Adapter strategies vary, but
the goal is visibility without stealing focus. When
the build is complete, load the results into the
|quickfix| list. The quickfix window is opened if
there are any matching errors. This command is
|quickfix| list and call |:cwindow|. This command is
preferred for shorter tasks like "build this file."

:Make! [arguments] Using the current compiler settings, dispatch a build
Expand Down

0 comments on commit b0ce647

Please sign in to comment.