Improve Quickfix List navigation
chadoh opened this issue · 6 comments
I'm coming from ag.vim (deprecated), which has some excellent keyboard shortcuts for the quickfix list:
e to open file and close the quickfix window
o to open (same as enter)
go to preview file (open but maintain focus on ag.vim results)
t to open in new tab
T to open in new tab silently
h to open in horizontal split
H to open in horizontal split silently
v to open in vertical split
gv to open in vertical split silently
q to close the quickfix window
The o
shortcut and the t
shortcut are particularly useful to me.
I'm not sure how to even use the quickfix list without these. I'm happy to learn a new way with Rg
, but I see no documentation about how to accomplish these things. Let me know if I'm missing something. I'm pretty busy these days, but I might be able to help out with a README improvement if you tell me the info to put in it, or where to find the info.
I figured out that I needed to turn off a vim shortcut I had for Enter
, which makes vim-ripgrep
at least usable. Extra keyboard shortcuts would still be great!
@chadoh I added shortcuts in my fork in case you would like to try https://github.com/miki725/vim-ripgrep
note that shortcuts dont match ag.vim to allow compatibility with https://github.com/stefandtw/quickfix-reflector.vim
@chadoh I just switched over to ripgrep and I was an ag.vim user for a long time and got accustomed to these quickfix shortcuts, too. But I see that you posted this over a year ago. Have you found a work-around?
@sudostack I use Enter and that’s it, now.
@chadoh eh! I've got a slight adjustment -- I use FZF as well, so I yank the relative file path from the search results then open FZF and paste and get a list of matching files (should be one), then from here I have the option of opening in current buffer or pressing t to open in a new tab.
However, just doing what @miki725 works, too. I guess we could simply just add those bindings ourselves. I removed ag from my system, so there shouldn't be any issues
@chadoh I added shortcuts in my fork in case you would like to try https://github.com/miki725/vim-ripgrep
note that shortcuts dont match ag.vim to allow compatibility with https://github.com/stefandtw/quickfix-reflector.vim
Have you tried bringing these into the main project by making a PR? I would also appreciate these shortcuts. Thanks!
[@miki725, on the other hand, you've done a lot of great work before, so I feel ok switching to your fork! This repo seems unmaintained anyways...]