if you want to always have it opened in vertical split with your current window, try next function:
augroup quickfix
autocmd!
autocmd QuickFixCmdPost [^l]* call OpenQuickFixList()
augroup END
function OpenQuickFixList()
wincmd o
vert cwindow
wincmd p
wincmd =
endfunction
What it does is
- make current window the only one (
:h wincmd
) - vertically split cwindow
- goes to previous window (remove this line if you want to stay in quickfix)
- make windows equal
PS