Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在使用CtrlP插件通过按 切换到 Vim 中的其他文件Ctrl-p。但这仅适用于正常模式。我也想通过在插入模式下按相同的一组键来触发它。我怎样才能做到这一点?我在帮助文档中找不到插入模式的任何映射。
Ctrl-p
试过了inoremap <C-p> <Esc>:CtrlP<CR>,它奏效了。归功于@statox,他在这里回答了这个问题
inoremap <C-p> <Esc>:CtrlP<CR>