As already mentioned by @ryuichiro, and then quoted by @Alistair Colling, the quickfix documentation (:h quickfix and :hquickref) provides an answer for how to open files within a quickfix list:
You can use :.cc
to jump to the error under the cursor.
Hitting the <Enter>
key or double-clicking the mouse on a line has the same
effect. The file containing the error is opened in the window above the
quickfix window.
Make sure that your <Enter>
Key (<CR>
) is not mapped so that it properly works. As already mentioned by @ryuichiro, this can be checked with
:verbose map <CR>
If you have a global mapping for <CR>
(e.g. in my case a mapping from the NERDtree plugin), you can undefine it just for when you are within a quickfix list based on adding the following line to your ~/.vimrc
as explained here:
autocmd BufReadPost quickfix nnoremap <buffer> <CR> <CR>
:h quickfix
and:h quickref
. Good luck! :-):verbose map <CR>
.autocmd BufReadPost quickfix nnoremap <buffer> <CR> <CR>
in your~/.vimrc
to undefine the mapping for quickfix as pointed out here