vim ftplugin/man.vim
有一个插件:
https://github.com/idbrii/vim-man/blob/master/ftplugin/man.vim
“手册页文件类型插件文件
有了它,我可以通过按“K”直接从vim查看手册页。
但滚动此内部手册页查看器不适用于pgup / pgdn键。是的,还有一些其他的滚动变体,但如何在这个插件中启用pgdn / pgup?
答案 0 :(得分:1)
添加到vimrc:
:let manpageview_multimanpage=0
pgup-pgdn映射到mans的更改部分(当使用man -a
调用man并且在不同的部分中有相同的页面时)。文档位于http://www.drchip.org/astronaut/vim/doc/manpageview.txt.html
g:manpageview_multimanpage
g:manpageview_multimanpage (=1 by default)
This option means that the PageUp and PageDown keys
will be mapped to move to the next and previous manpage
in a multi-man-page buffer. Such buffers result with
the "man -a" option. As an example:
:Man -a printf