put cursor on found text in less or vi?
Paul Smith
paul at mad-scientist.net
Fri Sep 27 15:35:29 UTC 2024
On Fri, 2024-09-27 at 11:45 +0200, Volker Wysk wrote:
> (define-key global-map "\e[1~" 'beginning-of-line)
> (define-key global-map [home] 'beginning-of-line)
> (define-key global-map "\e[4~" 'end-of-line)
> (define-key global-map [end] 'end-of-line)
This is the same as the default behavior, as far as I can tell, so you
don't need this. But, this won't do what was requested as it goes to
the beginning of the logical line not the start of the visual line.
> (define-key global-map [C-prior] 'beginning-of-buffer)
> (define-key global-map [C-next] 'end-of-buffer)
You can add extra keybindings, of course, but this isn't needed to
achieve the behavior asked for. Especially for new folks I think it's
not a good idea to add extra unasked-for stuff, as they may not realize
that it's extra rather than required.
More information about the ubuntu-users
mailing list