gpt4 book ai didi

vim - NERDTree 切换和键盘映射

转载 作者:行者123 更新时间:2023-12-04 00:09:25 27 4
gpt4 key购买 nike

我的 .vimrc 中有这一行:

nmap <silent> <Leader>p :NERDTreeToggle<CR>

那么切换 NERDTree 的热键是什么?

如何将其重新映射到 CTRL-D?
nmap 和有什么不一样, map , nnoremap , inoremap , 等等?

最佳答案

在正常模式下重新映射使用

nmap <silent> <C-D> :NERDTreeToggle<CR>
nmap表示正常模式下的 map imap表示插入模式下的映射
nore参加 nnoremap及其 friend 防止递归扩展映射。例如,我曾经也隐藏搜索字符串,所以在我的 vimrc 中我有
nnoremap <silent> <C-L> :noh<CR><C-L>

没有 nore ,上面的映射将循环。

关于vim - NERDTree 切换和键盘映射,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1438042/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com