From time to time I want to search on the list of my currents mappings. I search either for mapped keys (what
/<Space>a does?) or for a command (What keys are mapped on
I know that I can output these mappings with
:vmap, etc...) but this open a window where I can only scroll and not use search mode
So when I want to search in this list I have to use
redir to put the result of the command in a new file, which I then open in vim and use search mode:
:redir > foo :map :redir END :e foo
I feel like this workflow is not natural:
- It uses a lots of commands compared to what I want to do.
- It creates a new file that I have to delete.
So my question is is there a more natural way to do a search in the currently mapped keys?
I know that I could create a function which would executes these commands and a custom command to easily call the function, but I was wondering if there wouldn't be a more straight forward way to do it.