Prevent q from quitting lnav
Hi,
is it possible to prevent q from quitting lnav altogether. I keep doing it for some reason. Same about carl-c. Maybe a confirmation before quitting? Sorry if this has been asked before. Haven’t been able to find a solution for this for a long time. Otherwise, I love lnav. Thank you much.
The key binding for q is defined here:
https://github.com/tstack/lnav/blob/4a203f8618450ff7a1a18bbac776daae7e103da8/src/keymaps/default-keymap.json#L178-L180
You can rebind with a command like the following:
:config /ui/keymap-defs/default/x71/command :echo Press Shift-Q to quit
To me the issue with q quitting is that, it is the same key to close the overlay windows. I don't see any indication how many are left so might frequently quit one too many.
@tstack, thank you very much for that solution! Exactly what I needed.
@takeda Yes, I agree and had filed #1189 to track the issue with the stack of views not being shown. Since that one is open, I'm going to close this out.
Is it possible to disable CTRL+C as well?