When using vim, I often use the command /foo
to jump to some variable foo
in a file to look at it. I then remember the line number, press escape and then do :lno
to jump to the line number. Is there an easy way to escape search so that my cursor is located at foo
(without remembering the line number)?
This question is similar but not write right, as there may be multiple instances of foo
in my file. Jump to function definition in vim