在 Vim 中,如何将“\”重新映射为“,”以便在相反方向重复搜索
in Vim, how to remap "\" as "," for repeat search in opposite direction
在Vim中,,
的函数是:
repeat latest f, t, F or T in opposite direction [count] times.
但之后:
:let mapleader = ","
,
不能再用作重复最新搜索。
如何将 \
重新映射为 ,
,以便在相反方向重复最近的搜索。
你可以做到
:nnoremap \ ,
来自:h nnoremap
Map the key sequence {lhs} to {rhs} for the modes
where the map command applies. Disallow mapping of
{rhs}, to avoid nested and recursive mappings. Often
used to redefine a command.
在Vim中,,
的函数是:
repeat latest f, t, F or T in opposite direction [count] times.
但之后:
:let mapleader = ","
,
不能再用作重复最新搜索。
如何将 \
重新映射为 ,
,以便在相反方向重复最近的搜索。
你可以做到
:nnoremap \ ,
来自:h nnoremap
Map the key sequence {lhs} to {rhs} for the modes
where the map command applies. Disallow mapping of
{rhs}, to avoid nested and recursive mappings. Often
used to redefine a command.